Commit graph

34 commits

Author SHA1 Message Date
Sylvestre Ledru
955b100517 github/action: improve the clippy run
freebsd was detecting issues the linux jobs were not
2025-09-25 22:05:22 +02:00
renovate[bot]
60f04300c6
chore(deps): update actions/setup-python action to v6 2025-09-04 05:37:26 +00:00
Etienne
bba4d99042
add support for systemd-logind (#8483)
Some checks are pending
CICD / Build/stable (push) Blocked by required conditions
GnuTests / Run GNU tests (native) (push) Waiting to run
GnuTests / Run GNU tests (SELinux) (push) Waiting to run
Devcontainer / Verify devcontainer (push) Waiting to run
L10n (Localization) / L10n/Installation Test (Make & Cargo) (push) Waiting to run
L10n (Localization) / L10n/Locale Support Verification (push) Waiting to run
L10n (Localization) / L10n/Locale Embedding Regression Test (push) Waiting to run
L10n (Localization) / L10n/French Integration Test (push) Waiting to run
L10n (Localization) / L10n/Multi-call Binary Install Test (push) Waiting to run
WSL2 / Test (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 / Separate Builds (push) Waiting to run
CICD / Build/SELinux (push) Blocked by required conditions
GnuTests / Aggregate GNU test results (push) Blocked by required conditions
Android / Test builds (push) Waiting to run
Code Quality / Style/Python (push) Waiting to run
Code Quality / Style/toml (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 / Pre-commit hooks (push) Waiting to run
FreeBSD / Style and Lint (push) Waiting to run
FreeBSD / Tests (push) Waiting to run
L10n (Localization) / L10n/Build and Test (push) Waiting to run
L10n (Localization) / L10n/Fluent Syntax Check (push) Waiting to run
L10n (Localization) / L10n/Clap Error Localization Test (push) Waiting to run
* add support for systemd-logind

Add support for systemd-logind for systems where `/var/run/utmp` does not exist any more (e.g. Ubuntu 25.04).

Here is some context explaining the switch from utmp to systemd-logind:
https://www.thkukuk.de/blog/Y2038_glibc_utmp_64bit/

Fixes https://github.com/uutils/coreutils/issues/8376

Signed-off-by: Etienne Cordonnier <ecordonnier@snap.com>

* fix duplicated boot record

When feature feat_systemd_logind is enabled and utmp is present, two boot records were printed.

Signed-off-by: Etienne Cordonnier <ecordonnier@snap.com>

* improve error forwarding

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

* remove unnecessary negation in if/else block

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

* use getpwuid_r() instead of getpwuid()

getpwuid() is not thread-safe.

Signed-off-by: Etienne Cordonnier <ecordonnier@snap.com>

* improve error handling

Signed-off-by: Etienne Cordonnier <ecordonnier@snap.com>

* use Path instead of string

Signed-off-by: Etienne Cordonnier <ecordonnier@snap.com>

* use closure to reduce the number of clones() calls

Signed-off-by: Etienne Cordonnier <ecordonnier@snap.com>

* use MaybeUninit instead of mem::zeroed()

Signed-off-by: Etienne Cordonnier <ecordonnier@snap.com>

* systemd-logind: add some unit-tests

Signed-off-by: Etienne Cordonnier <ecordonnier@snap.com>

* use sysconf(_SC_GETPW_R_SIZE_MAX) instead of 1024

Signed-off-by: Etienne Cordonnier <ecordonnier@snap.com>

* fix cspell

Signed-off-by: Etienne Cordonnier <ecordonnier@snap.com>

* add auto-enablement of feat_systemd_logind in GNUmakefile

Signed-off-by: Etienne Cordonnier <ecordonnier@snap.com>

* Revert "add auto-enablement of feat_systemd_logind in GNUmakefile"

This breaks "Tests/BusyBox test suite" in CI.

This reverts commit 16626d4653.

---------

Signed-off-by: Etienne Cordonnier <ecordonnier@snap.com>
Co-authored-by: Daniel Hofstetter <daniel.hofstetter@42dh.com>
2025-08-23 19:05:40 +02:00
renovate[bot]
a1de8f7bf5
chore(deps): update actions/checkout action to v5 2025-08-11 15:31:34 +00:00
Sylvestre Ledru
aa4a85a4ff add a job to verify that pre-commit works 2025-06-21 21:15:15 +02:00
Nicolas Boichat
7854efc802 code-quality.yml: Clippy with --all-features and --workspace on ubuntu
Without this, some uucore packages are not properly tested.
2025-05-29 13:55:32 +02:00
Daniel Hofstetter
04ca61dce4 ci: run "cargo fmt --check" in fuzz folder 2025-05-19 14:38:07 +02:00
Daniel Hofstetter
32dcaeef32 Move clippy lints from CI to Cargo.toml 2025-04-13 17:35:05 +02:00
Sylvestre Ledru
b530fdcc88 github/action: on fork, run the CI for all the branches (currently: only main) 2025-03-28 17:06:20 +01:00
renovate[bot]
47e7062ada
chore(deps): update mozilla-actions/sccache-action action to v0.0.9 2025-03-27 12:48:09 +00:00
Nicolas Boichat
28bfac3c3c ci: Enable cspell on test on dotfiles too
Noticed this because pre-commit would try to run on dotfiles as
well (will CI ignored it)
2025-03-26 16:50:08 +01:00
Nicolas Boichat
b92144180f dotfiles: Add works to cspell dictionary
Also fix a couple of real spelling mistakes.
2025-03-26 16:49:21 +01:00
Sylvestre Ledru
302f7842c7 ci: if FAIL => PASS but in the intermittent list, show the info
see:
https://github.com/uutils/coreutils/pull/7522#issuecomment-2744892884
2025-03-22 11:04:20 +01:00
Sylvestre Ledru
e61898897d Github action: run ruff on the python code 2025-03-18 20:52:46 +01:00
renovate[bot]
56a965e04f
chore(deps): update mozilla-actions/sccache-action action to v0.0.8 2025-03-07 14:00:47 +00:00
Dorian Peron
e8141d3360 Add --tests to CICD clippy call 2024-12-29 04:40:07 +01:00
David Campbell
8ba264fa27 Use the env variable STYLE_FAIL_ON_FAULT. 2024-12-19 09:08:44 +01:00
David Campbell
655defd15c
Set persist-credentials: false 2024-12-18 21:27:34 -05:00
renovate[bot]
91ea45956f
chore(deps): update mozilla-actions/sccache-action action to v0.0.7 2024-12-12 14:08:04 +00:00
renovate[bot]
6fd3c78513
chore(deps): update mozilla-actions/sccache-action action to v0.0.6 2024-09-27 10:35:36 +00:00
renovate[bot]
5f2be86553
chore(deps): update mozilla-actions/sccache-action action to v0.0.5 2024-06-17 12:16:12 +00:00
Daniel Hofstetter
2ee782fcf1 ci: remove unused CARGO_FEATURES_OPTION 2024-04-21 01:26:50 +02:00
Daniel Hofstetter
bde10cd9c6 ci: use -pcoreutils when running clippy
instead of using -putil_1 -putil2 etc.
2024-04-21 01:26:50 +02:00
Sylvestre Ledru
0a0a7b9ba1 clippy: enable match_bool 2024-04-03 09:28:26 +02:00
renovate[bot]
ffda2a4b40 chore(deps): update nick-fields/retry action to v3 2024-04-01 17:09:59 +02:00
Ulrich Hornung
1c0adba1ca
fix macos ci instability on clippy with retry 2024-03-31 17:46:52 +02:00
Daniel Hofstetter
921cbe4dba ci: use latest version of cspell 2024-02-05 09:12:52 +01:00
renovate[bot]
ae714001da
chore(deps): update mozilla-actions/sccache-action action to v0.0.4 2024-01-30 14:03:51 +00:00
kralo
43212c6d89 ci: include more clippy complaints 2024-01-28 09:42:40 +01:00
Piotr Kwiecinski
4d2bdf497a prevent CI creating 2 events on each pull request push 2023-12-01 11:52:23 +01:00
Kostiantyn Hryshchuk
6ac1af6953 Fix clippy::implicit_clone 2023-11-04 21:04:29 +01:00
Miles Liu
cd51eb8eb5
ci: code-quality workflow doesn't fail on clippy errors 2023-10-13 14:13:10 +08:00
Sylvestre Ledru
02ab93c141 github action: name the toml task 2023-10-08 17:54:36 +02:00
Sylvestre Ledru
4d122d7dd0 Move rustfmt + clippy + typo check into it own workflow 2023-10-08 17:53:19 +02:00