* Parsing echo flags manually without clap as clap introduced various problematic interactions with hyphens
* fixed error where multiple flags would parse wrong
* Spelling & formatting fixes
* docu for EchoFlag struct
* more extensive comment/documentation
* revert POSIXLY_CORRECT check to only check if it is set
* Fixed problem of overwriting flags. Added test for same issue
* cargo fmt
* cspell
* Update src/uu/echo/src/echo.rs
Enabling POSIXLY_CORRECT flag if value is not UTF-8
Co-authored-by: Jan Verbeek <jan.verbeek@posteo.nl>
---------
Co-authored-by: Jan Verbeek <jan.verbeek@posteo.nl>
* fixes#7763
- introduce macOS-specific config guard
- added test for testing tail stdin when redirected (`>`) from file and
when through a pipe (`|`)
* created test to mock behavior in #7763, with comments
added drop line
* re-enabled test_stdin_redirect_dir_when_target_os_is_macos, and added a check to handle error message
* added location of current directory so test env can find script
* adjusting to try to have FreeBSD find the file in CI test
* putting in /env instead of assuming bash
* removed ignore macro
* added comments explaining the need for specific macOS cases, including reference to rust-lang issue: https://github.com/rust-lang/rust/issues/95239
* expr: Fix regex escape logic
We have to track if the previous character was already escaped to determine
if the '\' character should be interpreted as an escape character.
* expr: Fix parsing caret (^) as character class negation token
* expr: Add tests for parsing carets in regex
* expr: Add missing semicolon
* expr: Simplify boolean assignment
Co-authored-by: Daniel Hofstetter <daniel.hofstetter@42dh.com>
---------
Co-authored-by: Daniel Hofstetter <daniel.hofstetter@42dh.com>
* update chrono crate version and switch to new_lenient use
* bring back custom_tz_fmt and update test
* update chrono version in fuzz lock file
* replace boxing with parse_to_owned
* expr: Escape anchor characters within the core pattern
The anchor characters `^` and `$` are not considered special characters by `expr`
unless they are used as expected on the start or end of the pattern.
* id: Handle NULL pointer gracefully within `cstr2cow` macro
> getlogin() returns a pointer to a string containing the name of the user logged in on the controlling terminal of the process, or a NULL pointer if this information cannot be determined.
Ref: https://linux.die.net/man/3/getlogin
* id: Remove redundant std::ffi:: prefix from CStr
* id: Add comment for the null check
Co-authored-by: Sylvestre Ledru <sylvestre@debian.org>
* id: Remove skip for test that should not segfault anymore
Segfault fixed by 292fb9242342d47412a789f4d0002b811568bd41
---------
Co-authored-by: Sylvestre Ledru <sylvestre@debian.org>