Commit graph

9202 commits

Author SHA1 Message Date
mattsu
43dd238fea
od: make GNU test od.pl pass (#9334)
* feat: Add support for long double floating-point numbers and refine general float formatting.

* feat: Enhance `od` error reporting for file I/O, width, and offset parsing, including overflow detection and input validation.

* feat: Improve long double parsing by converting f128 to f64, enhance overflow error reporting with `libc::ERANGE`, and prevent final offset printing on input errors.

* style: Apply minor formatting adjustments across the `od` module.

* refactor: simplify float formatting logic and update string handling syntax

* fix: Correct float formatting logic to use decimal for numbers within range and exponential otherwise.

* refactor(test): use helper function in test_calculate_alignment

Replace repetitive assert_eq! calls with a new assert_alignment helper
to improve test readability and reduce code duplication. The helper
encapsulates alignment checks for OutputInfo::calculate_alignment,
making tests clearer and easier to maintain.

* feat(cspell): add ERANGE to jargon wordlist

Added "ERANGE" to the dictionary to prevent spell checker flagging it as a misspelling, as it's a valid errno constant from C libraries.

* feat(od): improve width error handling and subnormal float output

Refactor width option parsing in OdOptions to use i18n-compatible error messages via translate! macro, consolidating redundant error branches for better maintainability. Enhance float formatting for f16 and bf16 by introducing format_binary16_like helper to properly display subnormal values with exponential notation, removing the obsolete format_float_simple function and adding subnormal detection functions for accurate representation in od's output.

* refactor(od): simplify format_item_bf16 by removing redundant variable

Remove unnecessary `value` variable in `format_item_bf16` function, eliminating
a redundant cast and inline `f` directly for clarity and minor efficiency gain.

* fix(od): standardize option names in error messages

Remove hardcoded "--" prefixes from localization strings in en-US.ftl and fr-FR.ftl, replacing with a computed display name that includes "--" and optionally the short form (e.g., "--option" or "--option, -s"). Update parse_bytes_option and read_bytes functions to pass an option_display_name, enabling consistent error message formatting across localizations. Add validation to reject zero width values as invalid arguments. Improves user experience by providing clearer, more consistent option references in error outputs.

* refactor: condense format! macro in format_item_bf16 for readability

Removed unnecessary line breaks in the format! expression, keeping the code more concise while maintaining functionality. This improves code style in the float printing module.

* fix(od): add external quoting for filenames in error messages

The MultifileReader now uses `fname.maybe_quote().external(true)` when displaying permission and I/O errors, ensuring filenames are properly quoted for user-facing output (e.g., handling special characters that might confuse shells). This prevents potential issues with filename display in error logs.

* refactor(od): Rename f128_to_f64 to u128_to_f64 for clarity

Renamed the function in input_decoder.rs from f128_to_f64 to u128_to_f64
to accurately reflect its purpose of converting u128 integer bits to f64,
improving code readability and reducing potential confusion over float types.

* refactor(od): simplify error handling in OdOptions using combinators

Use map_err and the try operator to replace a verbose match statement,
making the code more concise and idiomatic Rust. This improves readability
without altering functionality.

* Update src/uu/od/src/od.rs

Co-authored-by: Daniel Hofstetter <daniel.hofstetter@42dh.com>

* Update src/uu/od/src/od.rs

Co-authored-by: Daniel Hofstetter <daniel.hofstetter@42dh.com>

* Update src/uu/od/src/parse_inputs.rs

Co-authored-by: Daniel Hofstetter <daniel.hofstetter@42dh.com>

* Update src/uu/od/src/od.rs

Co-authored-by: Daniel Hofstetter <daniel.hofstetter@42dh.com>

* Update src/uu/od/src/parse_inputs.rs

Co-authored-by: Daniel Hofstetter <daniel.hofstetter@42dh.com>

* Update src/uu/od/src/parse_inputs.rs

Co-authored-by: Daniel Hofstetter <daniel.hofstetter@42dh.com>

* refactor(od): remove leaking from translated error messages in parse_offset_operand

Eliminated use of `.leak()` and unnecessary `.to_string()` calls on translated error strings in the `parse_offset_operand` function. This simplifies error handling, improves memory safety by avoiding intentional leaks, and makes the code cleaner without functional changes.

---------

Co-authored-by: Daniel Hofstetter <daniel.hofstetter@42dh.com>
2025-11-28 08:23:55 +01:00
Daniel Hofstetter
b8da17d925
env: remove outdated comment (#9496) 2025-11-27 20:37:14 +01:00
mattsu
b9f97d4c7d
fix(seq): handle BrokenPipe like GNU (#9471)
Some checks are pending
CICD / Documentation/warnings (push) Waiting to run
CICD / MinRustV (push) Waiting to run
CICD / Dependencies (push) Waiting to run
CICD / Build/Makefile (push) Blocked by required conditions
CICD / Build/nightly (push) Blocked by required conditions
CICD / Binary sizes (push) Blocked by required conditions
CICD / Tests/Toybox test suite (push) Blocked by required conditions
CICD / Code Coverage (push) Waiting to run
CICD / Separate Builds (push) Waiting to run
CICD / Test all features separately (push) Blocked by required conditions
CICD / Build/SELinux (push) Blocked by required conditions
CICD / Build/SELinux-Stubs (Non-Linux) (push) Blocked by required conditions
CICD / Safe Traversal Security Check (push) Blocked by required conditions
GnuTests / Run GNU tests (native) (push) Waiting to run
GnuTests / Run GNU tests (SELinux) (push) Waiting to run
GnuTests / Aggregate GNU test results (push) Blocked by required conditions
Android / Test builds (push) Waiting to run
Benchmarks / Run benchmarks (CodSpeed) (push) Waiting to run
Code Quality / Style/Python (push) Waiting to run
Code Quality / Style/format (push) Waiting to run
Code Quality / Style/lint (push) Waiting to run
Code Quality / Style/spelling (push) Waiting to run
Code Quality / Style/toml (push) Waiting to run
Code Quality / Pre-commit hooks (push) Waiting to run
Devcontainer / Verify devcontainer (push) Waiting to run
FreeBSD / Style and Lint (push) Waiting to run
FreeBSD / Tests (push) Waiting to run
OpenBSD / Style and Lint (push) Waiting to run
OpenBSD / Tests (push) Waiting to run
WSL2 / Test (push) Waiting to run
* fix(seq): handle BrokenPipe like GNU

* test: add Unix-specific test for seq command broken pipe handling

- Ensures seq exits gracefully with code 0 and reports "Broken pipe" error on stderr when stdout pipe is prematurely closed
- Validates correct behavior for common scenario where output is piped to commands like head that terminate early

* refactor(test): translate Japanese comment to English in test_seq.rs

- Updated a comment in the test for broken pipe behavior to use English instead of Japanese, enhancing readability for non-Japanese speakers and aligning with project standards. No functional changes to the test logic.
2025-11-26 23:20:45 +01:00
Vikram Kangotra
df959b7e00
Merge pull request #9410 from vikram-kangotra/fix/ls-proc-self-fd-regression
ls: prevent ReadDir from closing before entries are processed
2025-11-26 23:15:04 +01:00
naoNao89
d655eed489 feat(cksum): improve debug output for single file operations
Some checks failed
CICD / Build/nightly (push) Blocked by required conditions
CICD / Binary sizes (push) Blocked by required conditions
CICD / Tests/BusyBox test suite (push) Blocked by required conditions
CICD / Tests/Toybox test suite (push) Blocked by required conditions
CICD / Code Coverage (push) Waiting to run
CICD / Separate Builds (push) Waiting to run
CICD / Test all features separately (push) Blocked by required conditions
CICD / Build/SELinux (push) Blocked by required conditions
CICD / Build/SELinux-Stubs (Non-Linux) (push) Blocked by required conditions
CICD / Safe Traversal Security Check (push) Blocked by required conditions
GnuTests / Run GNU tests (native) (push) Waiting to run
GnuTests / Run GNU tests (SELinux) (push) Waiting to run
GnuTests / Aggregate GNU test results (push) Blocked by required conditions
Android / Test builds (push) Waiting to run
Benchmarks / Run benchmarks (CodSpeed) (push) Waiting to run
Code Quality / Style/format (push) Waiting to run
Code Quality / Style/lint (push) Waiting to run
Code Quality / Style/spelling (push) Waiting to run
Code Quality / Style/toml (push) Waiting to run
Code Quality / Style/Python (push) Waiting to run
Code Quality / Pre-commit hooks (push) Waiting to run
Devcontainer / Verify devcontainer (push) Waiting to run
FreeBSD / Style and Lint (push) Waiting to run
OpenBSD / Style and Lint (push) Waiting to run
OpenBSD / Tests (push) Waiting to run
WSL2 / Test (push) Waiting to run
FreeBSD / Tests (push) Waiting to run
CheckScripts / ShellScript/Check (push) Has been cancelled
CheckScripts / ShellScript/Format (push) Has been cancelled
Check uudoc Documentation Generation / Verify uudoc generates correct documentation (push) Has been cancelled
2025-11-26 12:30:44 +01:00
Chris Dryden
824c5c7c93
stty: Implemented saved state parser for stty (#9480)
* Implemented saved state parser for stty

* Add compatibility to macos flag type

* Added many example state parsing integration tests with GNU compatibility checks and documentation

* Spelling and formatting fixes

* Matching behaviour of adding the help command after invocations and spelling fixes

* GNU tests were being skipped because they were not at the sufficient version

* Fixed messaging error for invalid states to not show full path

* Normalizing the test output and reverting lib change

* Discovered that the limit depends on platform specific values derived from a LIBC value

* Spelling fixes and setting flags to 0 for cross platform compatibility

* Clippy fixes

* Disabling tests due to invalid printing of control chars and using GNU for printing

* Redisabling failing test as outside of the scope of this PR

* Adding g prefix support to normalize stderr

* Spell checker fixes

* Normalizing command for both gnu and uutils output

* removing single value from testing since it can be interpreted as Baud rate

* Fixing spelling mistake
2025-11-26 07:33:26 +01:00
naoNao89
8d740257ac feat(uucore): add shared hardware detection module
Some checks are pending
CICD / Build/stable (push) Blocked by required conditions
CICD / Build/nightly (push) Blocked by required conditions
CICD / Binary sizes (push) Blocked by required conditions
CICD / Build (push) Blocked by required conditions
CICD / Tests/BusyBox test suite (push) Blocked by required conditions
CICD / Tests/Toybox test suite (push) Blocked by required conditions
CICD / Code Coverage (push) Waiting to run
CICD / Test all features separately (push) Blocked by required conditions
CICD / Build/SELinux (push) Blocked by required conditions
CICD / Build/SELinux-Stubs (Non-Linux) (push) Blocked by required conditions
CICD / Safe Traversal Security Check (push) Blocked by required conditions
CheckScripts / ShellScript/Check (push) Waiting to run
CheckScripts / ShellScript/Format (push) Waiting to run
GnuTests / Run GNU tests (native) (push) Waiting to run
GnuTests / Run GNU tests (SELinux) (push) Waiting to run
GnuTests / Aggregate GNU test results (push) Blocked by required conditions
Android / Test builds (push) Waiting to run
Benchmarks / Run benchmarks (CodSpeed) (push) Waiting to run
Code Quality / Style/Python (push) Waiting to run
Code Quality / Style/format (push) Waiting to run
Code Quality / Style/lint (push) Waiting to run
Code Quality / Style/spelling (push) Waiting to run
Code Quality / Style/toml (push) Waiting to run
Code Quality / Pre-commit hooks (push) Waiting to run
Devcontainer / Verify devcontainer (push) Waiting to run
FreeBSD / Style and Lint (push) Waiting to run
FreeBSD / Tests (push) Waiting to run
OpenBSD / Style and Lint (push) Waiting to run
OpenBSD / Tests (push) Waiting to run
WSL2 / Test (push) Waiting to run
Add shared CPU hardware capability detection in uucore to prevent
code duplication across utilities. This provides a unified interface
for detecting CPU features (AVX512, AVX2, PCLMUL, SSE2, ASIMD) and
respecting GLIBC_TUNABLES environment variable.

This unblocks PR #9088 (cksum --debug) and PR #9144 (wc --debug) by
providing a common implementation that both utilities can use.

Features:
- CPU feature detection with caching (singleton pattern)
- GLIBC_TUNABLES parsing for hwcaps restrictions
- Cross-platform support (x86/x86_64, aarch64)
- Comprehensive test coverage
- Zero-cost abstractions using std::arch

Implementation details:
- Uses std::arch feature detection (no external deps for detection)
- Adds cfg-if dependency for conditional compilation
- Feature-gated behind "hardware" feature flag
- Android excluded (no CPUID access in sandboxed environment)

Related: #9088, #9144
2025-11-24 12:53:58 +01:00
Chris Dryden
6a2b97273e
stty: baud parsing integration tests and validation (#9454)
* Adding comprehensive gnu suite baud parsing rules

* Adding missing spellcheck words

* Fixed clippy errors and simplified rounding logic
2025-11-24 11:03:47 +01:00
Daniel Hofstetter
b5561e7615
Merge pull request #9342 from FidelSch/ln-dir-hardlink
Some checks failed
CICD / Separate Builds (push) Waiting to run
CICD / Binary sizes (push) Blocked by required conditions
CICD / Build (push) Blocked by required conditions
CICD / Tests/BusyBox test suite (push) Blocked by required conditions
CICD / Tests/Toybox test suite (push) Blocked by required conditions
CICD / Code Coverage (push) Waiting to run
CICD / Test all features separately (push) Blocked by required conditions
CICD / Build/SELinux (push) Blocked by required conditions
CICD / Build/SELinux-Stubs (Non-Linux) (push) Blocked by required conditions
CICD / Safe Traversal Security Check (push) Blocked by required conditions
GnuTests / Run GNU tests (native) (push) Waiting to run
GnuTests / Run GNU tests (SELinux) (push) Waiting to run
GnuTests / Aggregate GNU test results (push) Blocked by required conditions
Android / Test builds (push) Waiting to run
Benchmarks / Run benchmarks (CodSpeed) (push) Waiting to run
Code Quality / Style/format (push) Waiting to run
Code Quality / Style/lint (push) Waiting to run
Code Quality / Style/spelling (push) Waiting to run
Code Quality / Style/toml (push) Waiting to run
Devcontainer / Verify devcontainer (push) Waiting to run
OpenBSD / Style and Lint (push) Waiting to run
OpenBSD / Tests (push) Waiting to run
WSL2 / Test (push) Waiting to run
Code Quality / Style/Python (push) Waiting to run
Code Quality / Pre-commit hooks (push) Waiting to run
FreeBSD / Style and Lint (push) Waiting to run
FreeBSD / Tests (push) Waiting to run
CheckScripts / ShellScript/Check (push) Has been cancelled
CheckScripts / ShellScript/Format (push) Has been cancelled
Check uudoc Documentation Generation / Verify uudoc generates correct documentation (push) Has been cancelled
ln: add error handling for hard link creation on directories
2025-11-21 11:15:39 +01:00
Sylvestre Ledru
bbec8fea08
Merge pull request #9344 from RenjiSann/cksum-fix-base64-untagged
cksum: Fix GNU test cksum-base64-untagged
2025-11-21 06:43:42 +01:00
naoNao89
e0c7ef7b10 fix(stdbuf): remove unsafe unwrap() calls for proper error handling
- Replace get_many().unwrap() with ok_or_else() to handle missing command
- Replace next().unwrap() with pattern matching for safety
- Replace tempdir().unwrap() with map_err() to handle temp dir failures

All stdbuf internal errors now properly exit with code 125 per GNU specification:
https://www.gnu.org/s/coreutils/manual/html_node/stdbuf-invocation.html
2025-11-21 08:04:56 +07:00
Dorian Péron
7b47d581d5 checksum: fix GNU test cksum-base64-untagged.sh 2025-11-21 00:24:29 +01:00
FidelSch
2b8e67bee2 ln: Allow hard links to soft links even when they poin to a directory 2025-11-20 10:56:55 -03:00
Chris Dryden
2a314c7ff3
fold: Adding combining character support (#9328)
Some checks are pending
CICD / Dependencies (push) Waiting to run
CICD / Build/Makefile (push) Blocked by required conditions
CICD / Build/stable (push) Blocked by required conditions
CICD / Build/nightly (push) Blocked by required conditions
CICD / Binary sizes (push) Blocked by required conditions
CICD / Build (push) Blocked by required conditions
CICD / Tests/BusyBox test suite (push) Blocked by required conditions
CICD / Tests/Toybox test suite (push) Blocked by required conditions
CICD / Code Coverage (push) Waiting to run
CICD / Test all features separately (push) Blocked by required conditions
CICD / Build/SELinux (push) Blocked by required conditions
CICD / Build/SELinux-Stubs (Non-Linux) (push) Blocked by required conditions
CICD / Safe Traversal Security Check (push) Blocked by required conditions
GnuTests / Run GNU tests (native) (push) Waiting to run
GnuTests / Run GNU tests (SELinux) (push) Waiting to run
GnuTests / Aggregate GNU test results (push) Blocked by required conditions
Android / Test builds (push) Waiting to run
Benchmarks / Run benchmarks (CodSpeed) (push) Waiting to run
Code Quality / Style/format (push) Waiting to run
Code Quality / Style/lint (push) Waiting to run
Code Quality / Style/spelling (push) Waiting to run
Code Quality / Style/toml (push) Waiting to run
Code Quality / Style/Python (push) Waiting to run
Code Quality / Pre-commit hooks (push) Waiting to run
Devcontainer / Verify devcontainer (push) Waiting to run
FreeBSD / Style and Lint (push) Waiting to run
FreeBSD / Tests (push) Waiting to run
OpenBSD / Style and Lint (push) Waiting to run
OpenBSD / Tests (push) Waiting to run
WSL2 / Test (push) Waiting to run
* Adding combining character support for fold

* add fullwidth to the spell ignore list

* addressing comments and cargo fmt fixes

* clippy fixes for test files

---------

Co-authored-by: Christopher Illarionova <drydench@amazon.com>
Co-authored-by: Sylvestre Ledru <sylvestre@debian.org>
2025-11-20 09:36:56 +01:00
Sylvestre Ledru
643a72c75d
Merge pull request #9135 from RenjiSann/cksum-reworks
cksum/hashsum: merge digest computation & various improvements
2025-11-20 06:18:56 +01:00
FidelSch
4b02a38be5 ln: add error handling for hard link creation on directories 2025-11-19 20:36:26 -03:00
Vikram Kangotra
15d22c285e
cp: allow directory merging when destination was just created (#9325)
Some checks failed
CICD / Build/stable (push) Blocked by required conditions
CICD / Build/nightly (push) Blocked by required conditions
CICD / Binary sizes (push) Blocked by required conditions
CICD / Build (push) Blocked by required conditions
CICD / Tests/BusyBox test suite (push) Blocked by required conditions
CICD / Tests/Toybox test suite (push) Blocked by required conditions
CICD / Code Coverage (push) Waiting to run
CICD / Test all features separately (push) Blocked by required conditions
CICD / Build/SELinux (push) Blocked by required conditions
CICD / Build/SELinux-Stubs (Non-Linux) (push) Blocked by required conditions
CICD / Safe Traversal Security Check (push) Blocked by required conditions
GnuTests / Run GNU tests (native) (push) Waiting to run
GnuTests / Run GNU tests (SELinux) (push) Waiting to run
GnuTests / Aggregate GNU test results (push) Blocked by required conditions
Android / Test builds (push) Waiting to run
Benchmarks / Run benchmarks (CodSpeed) (push) Waiting to run
Code Quality / Style/format (push) Waiting to run
Code Quality / Style/lint (push) Waiting to run
Code Quality / Style/spelling (push) Waiting to run
Code Quality / Style/toml (push) Waiting to run
Code Quality / Style/Python (push) Waiting to run
Code Quality / Pre-commit hooks (push) Waiting to run
Devcontainer / Verify devcontainer (push) Waiting to run
FreeBSD / Style and Lint (push) Waiting to run
FreeBSD / Tests (push) Waiting to run
OpenBSD / Style and Lint (push) Waiting to run
OpenBSD / Tests (push) Waiting to run
WSL2 / Test (push) Waiting to run
CheckScripts / ShellScript/Check (push) Has been cancelled
CheckScripts / ShellScript/Format (push) Has been cancelled
* cp: allow directory merging when destination was just created

Previously, when copying to a destination that was created in the same
cp call, the operation would fail with "will not overwrite just-created"
for both files and directories. This change allows directories to be
merged (matching GNU cp behavior) while still preventing file
overwrites.

The fix checks if both the source and destination are directories
before allowing the merge. If either is a file, the original error
behavior is preserved to prevent accidental file overwrites.

Fixes the case where copying multiple directories to the same
destination path would incorrectly error instead of merging their
contents.

fixes: #9318

* test_cp: Update with the suggestion

Co-authored-by: Daniel Hofstetter <daniel.hofstetter@42dh.com>

---------

Co-authored-by: Daniel Hofstetter <daniel.hofstetter@42dh.com>
2025-11-19 16:53:23 +01:00
Dorian Peron
6d6a9917ad checksum: fix binary flag on windows, ignore test 2025-11-19 14:13:36 +01:00
Dorian Peron
c97ce1bb8e checksum: Adapt checksum computation to hashsum 2025-11-19 13:37:14 +01:00
Dorian Peron
3849d91d69 checksum: Move cksum computation to uucore::checksum 2025-11-19 13:37:14 +01:00
Dorian Peron
0b7289310d checksum: Create a sub-module for checksum validation 2025-11-18 18:19:22 +01:00
Dorian Peron
68dc6fd147 checksum: Get rid of detect_algo and child functions 2025-11-18 11:30:14 +01:00
Dorian Peron
923baae853 checksum: Always get bit length from the SizedAlgoKind 2025-11-18 11:30:14 +01:00
Dorian Peron
413e71de0e checksum: Introduce SizedAlgoKind to improve representation and cleanup 2025-11-18 11:30:14 +01:00
Dorian Peron
9b6dc9675c checksum: Introduce AlgoKind enum to rely less on string comparison 2025-11-18 11:30:14 +01:00
Dorian Peron
885082ce14 util(cksum): Fix BLAKE2b --length sanitization 2025-11-18 11:30:14 +01:00
Sylvestre Ledru
0709890328 replace number_prefix by unit-prefix
See https://rustsec.org/advisories/RUSTSEC-2025-0119
2025-11-18 09:59:46 +01:00
Sylvestre Ledru
055b1e2e76 shuf: add benchmarks
To test: https://github.com/uutils/coreutils/pull/7585
2025-11-18 08:42:06 +01:00
Sylvestre Ledru
267abb26f7
Merge pull request #9309 from cakebaker/bump_markdownlint_cli2_action
Some checks are pending
CICD / Dependencies (push) Waiting to run
CICD / Build/Makefile (push) Blocked by required conditions
CICD / Build/stable (push) Blocked by required conditions
CICD / Build/nightly (push) Blocked by required conditions
CICD / Binary sizes (push) Blocked by required conditions
CICD / Build (push) Blocked by required conditions
CICD / Tests/BusyBox test suite (push) Blocked by required conditions
CICD / Tests/Toybox test suite (push) Blocked by required conditions
CICD / Code Coverage (push) Waiting to run
CICD / Test all features separately (push) Blocked by required conditions
CICD / Build/SELinux (push) Blocked by required conditions
CICD / Build/SELinux-Stubs (Non-Linux) (push) Blocked by required conditions
CICD / Safe Traversal Security Check (push) Blocked by required conditions
GnuTests / Run GNU tests (native) (push) Waiting to run
GnuTests / Run GNU tests (SELinux) (push) Waiting to run
GnuTests / Aggregate GNU test results (push) Blocked by required conditions
Android / Test builds (push) Waiting to run
Benchmarks / Run benchmarks (CodSpeed) (push) Waiting to run
Code Quality / Style/format (push) Waiting to run
Code Quality / Style/lint (push) Waiting to run
Code Quality / Style/spelling (push) Waiting to run
Code Quality / Style/toml (push) Waiting to run
Code Quality / Style/Python (push) Waiting to run
Code Quality / Pre-commit hooks (push) Waiting to run
Devcontainer / Verify devcontainer (push) Waiting to run
FreeBSD / Style and Lint (push) Waiting to run
FreeBSD / Tests (push) Waiting to run
OpenBSD / Style and Lint (push) Waiting to run
OpenBSD / Tests (push) Waiting to run
WSL2 / Test (push) Waiting to run
Bump `markdownlint_cli2_action` & fix warnings
2025-11-17 16:12:05 +01:00
Daniel Hofstetter
29ec8f3998
Merge pull request #9311 from uutils/sylvestre-patch-2
Some checks are pending
CICD / Binary sizes (push) Blocked by required conditions
CICD / Build (push) Blocked by required conditions
CICD / Dependencies (push) Waiting to run
CICD / Build/Makefile (push) Blocked by required conditions
CICD / Build/stable (push) Blocked by required conditions
CICD / Build/nightly (push) Blocked by required conditions
CICD / Tests/BusyBox test suite (push) Blocked by required conditions
CICD / Tests/Toybox test suite (push) Blocked by required conditions
CICD / Code Coverage (push) Waiting to run
CICD / Test all features separately (push) Blocked by required conditions
CICD / Build/SELinux (push) Blocked by required conditions
CICD / Build/SELinux-Stubs (Non-Linux) (push) Blocked by required conditions
CICD / Safe Traversal Security Check (push) Blocked by required conditions
GnuTests / Run GNU tests (native) (push) Waiting to run
GnuTests / Run GNU tests (SELinux) (push) Waiting to run
GnuTests / Aggregate GNU test results (push) Blocked by required conditions
Android / Test builds (push) Waiting to run
Benchmarks / Run benchmarks (CodSpeed) (push) Waiting to run
Code Quality / Style/format (push) Waiting to run
Code Quality / Style/lint (push) Waiting to run
Code Quality / Style/spelling (push) Waiting to run
Code Quality / Style/toml (push) Waiting to run
Code Quality / Style/Python (push) Waiting to run
Code Quality / Pre-commit hooks (push) Waiting to run
Devcontainer / Verify devcontainer (push) Waiting to run
FreeBSD / Style and Lint (push) Waiting to run
FreeBSD / Tests (push) Waiting to run
OpenBSD / Style and Lint (push) Waiting to run
OpenBSD / Tests (push) Waiting to run
WSL2 / Test (push) Waiting to run
Remove high variance benchmark functions
2025-11-17 11:02:06 +01:00
Vesal Joolanejad
747874911a
Enhance mode parsing to support comma-separated mode strings in install command (#9298)
* Enhance mode parsing to support comma-separated mode strings in `parse` function. Add tests for comma-separated mode handling in file and directory creation.

* Add comprehensive tests for mode parsing in `parse` function, covering numeric, symbolic, and mixed modes, as well as handling of invalid inputs and umask considerations.

---------

Co-authored-by: Sylvestre Ledru <sylvestre@debian.org>
2025-11-17 10:14:22 +01:00
Sylvestre Ledru
c17598370c
Remove high variance benchmark functions 2025-11-17 10:11:40 +01:00
Daniel Hofstetter
e82cc75433 docs: fix warnings from markdownlint 2025-11-17 09:28:16 +01:00
Daniel Hofstetter
58ebeaf006
Merge pull request #9280 from naoNao89/fix-numfmt-test-failures
Some checks failed
CICD / Binary sizes (push) Blocked by required conditions
CICD / Build (push) Blocked by required conditions
CICD / Tests/BusyBox test suite (push) Blocked by required conditions
CICD / Tests/Toybox test suite (push) Blocked by required conditions
CICD / Code Coverage (push) Waiting to run
CICD / Separate Builds (push) Waiting to run
CICD / Test all features separately (push) Blocked by required conditions
CICD / Build/SELinux (push) Blocked by required conditions
CICD / Build/SELinux-Stubs (Non-Linux) (push) Blocked by required conditions
CICD / Safe Traversal Security Check (push) Blocked by required conditions
GnuTests / Run GNU tests (native) (push) Waiting to run
GnuTests / Run GNU tests (SELinux) (push) Waiting to run
GnuTests / Aggregate GNU test results (push) Blocked by required conditions
Android / Test builds (push) Waiting to run
Benchmarks / Run benchmarks (CodSpeed) (push) Waiting to run
Code Quality / Style/format (push) Waiting to run
Code Quality / Style/lint (push) Waiting to run
Code Quality / Style/spelling (push) Waiting to run
Code Quality / Style/toml (push) Waiting to run
Code Quality / Style/Python (push) Waiting to run
Code Quality / Pre-commit hooks (push) Waiting to run
Devcontainer / Verify devcontainer (push) Waiting to run
FreeBSD / Style and Lint (push) Waiting to run
FreeBSD / Tests (push) Waiting to run
OpenBSD / Style and Lint (push) Waiting to run
OpenBSD / Tests (push) Waiting to run
WSL2 / Test (push) Waiting to run
CheckScripts / ShellScript/Check (push) Has been cancelled
CheckScripts / ShellScript/Format (push) Has been cancelled
Check uudoc Documentation Generation / Verify uudoc generates correct documentation (push) Has been cancelled
numfmt: support quetta/ronna suffixes and fix error messages
2025-11-16 17:13:48 +01:00
Daniel Hofstetter
a15ee0927b
Merge pull request #9266 from sylvestre/sort-compress
sort: make compression program failures non-fatal, warn and fallback to plain files
2025-11-16 15:11:47 +01:00
Daniel Hofstetter
63ee6486d0
Merge pull request #9296 from sylvestre/divan
move the factor divan bench into the actual directory
2025-11-16 14:05:00 +01:00
Sylvestre Ledru
58c15d4d52
Merge pull request #9254 from akretz/install_ignore_umask
install: ignore umask
2025-11-15 22:27:45 +01:00
Sylvestre Ledru
ecc7f14e7e move the factor divan bench into the actual directory 2025-11-15 21:45:22 +01:00
Sylvestre Ledru
8b499009ad
Merge pull request #9245 from cakebaker/test_ot_nt_with_non_existing_file
test: existing file is newer than non-existing file
2025-11-15 20:38:16 +01:00
Sylvestre Ledru
09e1aa18ab sort: make compression program failures non-fatal, warn and fallback to plain files
Should fix tests/sort/sort-compress.sh
2025-11-15 20:30:41 +01:00
naoNao89
907c57396f numfmt: add Q/R/k suffixes and fix bugs
- Add quetta (Q), ronna (R) suffix support (10^30, 10^27)
- Support lowercase 'k' suffix
- Fix "invalid number" vs "invalid suffix" error distinction
- Fix output duplication on formatting errors
- Add regression tests

Improves GNU test suite compatibility.
2025-11-15 01:38:48 +07:00
Sylvestre Ledru
73d1bce20d
Merge pull request #9258 from oech3/wgetcurl
Avoid mixing wget and curl
2025-11-14 09:37:31 +01:00
Daniel Hofstetter
49f82da04d
Merge pull request #9252 from sylvestre/pr-fix
pr: fix header formatting for custom date formats starting with '+'
2025-11-14 08:48:59 +01:00
Sylvestre Ledru
fa82066cee pr: fix header formatting for custom date formats starting with '+'
Should fix tests/misc/time-style.sh
2025-11-13 21:14:44 +01:00
Daniel Hofstetter
e502d894dc test: existing file is newer than non-existing
existing -nt non-existing => true
non-existing -nt existing => false
existing -ot non-existing => false
non-existing -ot existing => true
2025-11-13 16:42:59 +01:00
oech3
913fe84224 Avoid mixing wget and curl 2025-11-13 23:58:11 +09:00
mattsu
4a48c9e35e
Merge pull request #9126 from mattsu2020/fold_fix
fix(fold): GNU fold-characters.sh test
2025-11-13 11:41:39 +01:00
Adrian Kretz
376b88ac72 install: ignore umask with symbolic mode 2025-11-13 00:30:30 +01:00
Daniel Hofstetter
d4321315f1
Merge pull request #9140 from naoNao89/fix/nl-repeated-flags-9132
Some checks failed
CICD / Dependencies (push) Waiting to run
CICD / Build/Makefile (push) Blocked by required conditions
CICD / Build/stable (push) Blocked by required conditions
CICD / Build/nightly (push) Blocked by required conditions
CICD / Binary sizes (push) Blocked by required conditions
CICD / Build (push) Blocked by required conditions
CICD / Tests/BusyBox test suite (push) Blocked by required conditions
CICD / Tests/Toybox test suite (push) Blocked by required conditions
CICD / Code Coverage (push) Waiting to run
CICD / Test all features separately (push) Blocked by required conditions
CICD / Build/SELinux (push) Blocked by required conditions
CICD / Build/SELinux-Stubs (Non-Linux) (push) Blocked by required conditions
CICD / Safe Traversal Security Check (push) Blocked by required conditions
GnuTests / Run GNU tests (native) (push) Has been cancelled
GnuTests / Run GNU tests (SELinux) (push) Has been cancelled
Android / Test builds (push) Has been cancelled
OpenBSD / Style and Lint (push) Has been cancelled
OpenBSD / Tests (push) Has been cancelled
Code Quality / Style/Python (push) Has been cancelled
Benchmarks / Run benchmarks (CodSpeed) (push) Has been cancelled
Code Quality / Style/format (push) Has been cancelled
Code Quality / Style/lint (push) Has been cancelled
Code Quality / Style/spelling (push) Has been cancelled
Code Quality / Style/toml (push) Has been cancelled
Code Quality / Pre-commit hooks (push) Has been cancelled
Devcontainer / Verify devcontainer (push) Has been cancelled
FreeBSD / Style and Lint (push) Has been cancelled
FreeBSD / Tests (push) Has been cancelled
WSL2 / Test (push) Has been cancelled
GnuTests / Aggregate GNU test results (push) Has been cancelled
fix(nl): allow repeated flags to match GNU nl behavior (fixes #9132)
2025-11-12 17:04:51 +01:00
naoNao89
abcfbe407e fix(nl): allow repeated flags to match GNU behavior
• Enable args_override_self(true) for repeated flags
• Remove unnecessary ArgAction::Append calls
• Fix tests to verify last value wins, not just succeeds
• Update test output validation for repeated flags

Fixes #9132
2025-11-12 21:06:25 +07:00