Commit Graph
20783 Commits
Author SHA1 Message Date
Sylvestre Ledru 517ee38cf1 chcon: cover the traversal semantics the fd-based walk relies on
The existing tests pass unchanged whether a directory is labelled before
or after its contents, whether a failed descent still relabels the
directory, and whether following symlinks reports a cycle. Each of those
went wrong while moving off fts and none of them was caught.

Lock in the four: post-order labelling, an unreadable directory being
reported and left alone, a symlink loop under -L staying quiet, and
operands with several path components.
2026-09-12 22:28:39 +02:00
Sylvestre Ledru 51c7a66300 comments: rewrite these comments to describe our own code 2026-09-12 22:23:10 +02:00
oech3 76e579935d use .is_root() of rustix::process 2026-09-12 18:40:20 +02:00
xtqqczze 1554443636 uucore: remove process functions 2026-09-12 16:48:16 +02:00
Devel 8df50eb861 factor: strip error code in stdin error message 2026-09-12 14:47:56 +02:00
xtqqczze 924987e45b Revert "chore(deps): update vmactions/freebsd-vm action to v1.5.6 (#12977)"
This reverts commit 055c1d985b.
2026-09-12 14:34:57 +02:00
Sylvestre Ledru 519b2a5148 github copilot: Create code review guidelines for uutils/coreutils (#14510) 2026-09-11 20:58:13 +00:00
Daniel Hofstetter c350a7c5ac pathchk: remove #![allow(unused_must_use)] 2026-09-11 22:01:03 +02:00
Daniel HofstetterandAlejandro Coronado c04ba563aa pathchk: reject empty path in portability mode
Co-Authored-By: Alejandro Coronado <alejandro.coronado.n@gmail.com>
2026-09-11 17:06:51 +02:00
Daniel Hofstetter 8c44cea005 Revert "env: trace the environment changes under -v"
This reverts commit 9408b4f2da.
2026-09-11 17:00:29 +02:00
oech3 b99b457b0e sort: simplify get_unit 2026-09-11 16:42:51 +02:00
oech3 5d76bc37a9 remove some matches! & use .get() 2026-09-11 13:49:29 +02:00
oech3 195f132a16 simplify matches! and inequalities in match 2026-09-11 11:29:30 +02:00
Develandxtqqczze 5d94dd570f run test only on linux, freebsd and netbsd
Co-authored-by: xtqqczze <45661989+xtqqczze@users.noreply.github.com>
2026-09-11 11:02:09 +02:00
Devel 4a96f35a41 expr: exit with on a write error 2026-09-11 11:02:09 +02:00
Luan Taraschi 26a1091b6f ls: break a tie in the time sort with the name
Every other sort in sort_entries falls back on the name when its key
ties. Sorting by time did not, so entries sharing a timestamp came out
in the order the directory was read in, and since the sort is unstable
that order was not guaranteed either.

GNU ls breaks the tie with the collation rather than with the bytes, so
the comparison Sort::Name already builds is hoisted out of the match and
the fallback uses that same one.
2026-09-11 10:34:03 +02:00
Sylvestre Ledru 51ed5dc4de CI: fail closed when the reference cannot be read
* .github/workflows/GnuTests.yml (Fetch reference results): Retry the
branch lookup and treat only a 404 as "nothing published yet"; a
transient API error used to look like a missing baseline and silently
skip both comparisons, letting a regression through unnoticed.
(Publish to the reference branch): Same for the published run id, which
guards the force-push.  A suppressed error read as run id 0 would let
this run overwrite a reference a newer run had already placed.
* .github/workflows/NotifyTracking.yml: Do not name a cadence for the
tracking repository's fallback schedule, which is its own to change.
2026-09-10 12:07:42 +02:00
Sylvestre Ledru cbb2643c82 CI: pin the reference read to one commit, notify on failed runs too
* .github/workflows/GnuTests.yml (Fetch reference results): Resolve the
reference branch tip once and read every file at that commit.  The
branch is force-pushed by 'publish-reference', so reading each file by
branch name could straddle a publish and pair one file with another
reference's, comparing against a baseline that never existed.
* .github/workflows/NotifyTracking.yml (jobs.dispatch.if): Dispatch for
any completed run, not only a successful one.  'GnuTests' uploads its
results and only then fails the comparison when it finds a new failure,
and 'publish-reference' publishes regardless, so requiring success left
the graphs un-refreshed for exactly the regressions they exist to show.
2026-09-10 12:07:42 +02:00
Sylvestre Ledru 05b0452518 CI: fix the reference publish race and the secrets conditional
* .github/workflows/NotifyTracking.yml (jobs.dispatch.env): Add
HAVE_APP_CREDENTIALS; the 'secrets' context is not available in a step's
'if:', where it fails with "Unrecognized named-value: 'secrets'", so the
check has to go through a job-level env var.
* .github/workflows/GnuTests.yml (jobs.publish-reference.concurrency):
Serialize publishing.  The step reads the published run id and then
force-pushes, so two overlapping runs could interleave those and let an
older one overwrite a newer reference.
2026-09-10 12:07:42 +02:00
Sylvestre Ledru 9aeedc1e35 CI: notify coreutils-tracking when its input data changes
* .github/workflows/NotifyTracking.yml: New workflow sending a
repository_dispatch to uutils/coreutils-tracking once 'GnuTests' or
'make' has finished on the default branch.

The tracking repository polled our artifacts on a cron, so its graphs
lagged the data by up to six hours.  Telling it when the data is ready
lets it refresh immediately; its schedule stays as a safety net.

A GITHUB_TOKEN only covers the repository it runs in, so this needs a
credential of its own: an organization-owned GitHub App installed on the
tracking repository, read from the TRACKING_APP_ID and
TRACKING_APP_PRIVATE_KEY secrets.  Without them the step warns and the
tracking repository keeps refreshing on its own schedule.
2026-09-10 12:07:42 +02:00
Sylvestre Ledru a62376afb7 CI: publish GNU reference results to a branch
* .github/workflows/GnuTests.yml (env): Add REFERENCE_BRANCH.
(on.push.branches): Exclude the reference branch, which carries no code.
(aggregate): Fetch the reference from that branch rather than resolving
and downloading a workflow artifact.
(publish-reference): New job publishing this run's results on a push to
the default branch.

An artifact is addressable only by run id, so finding one meant listing
workflow runs on the default branch.  That listing's 'branch' filter is
served by an eventually consistent index which intermittently returns a
snapshot weeks out of date, making every test fixed on the default
branch since then look like a fix contributed by the pull request.
2026-09-10 12:07:42 +02:00
renovate[bot] e9641f1b2a chore(deps): update rust crate console to v0.16.6 2026-09-10 11:09:25 +02:00
Socialpranker 9408b4f2da env: trace the environment changes under -v
-v printed only the exec, not what it did to the environment first, so
the three lines GNU emits before it were missing:

    $ env -v -u A FOO=1 true
    unset:    A
    setenv:   FOO=1
    executing: true
       arg[0]= 'true'

and 'cleaning environ' for -i. The individual unsets are not logged when
-i is in effect, since it has already emptied the environment.
2026-09-10 10:50:26 +02:00
oech3 1fb0a48ccb freebsd.yml: fix warning 2026-09-10 10:11:54 +02:00
Leonard Hecker 57b9a49083 dirname: Fix backslash support on Windows 2026-09-10 09:44:50 +02:00