Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -120,12 +120,12 @@ jobs:
# shadow-core's crypt(3) wrapper has musl-specific expectations (no
# yescrypt, `rounds=` honoured). Run its unit tests against the static
# musl libc, not only Alpine's dynamic one in the Docker matrix.
- run: cargo test --target x86_64-unknown-linux-musl -p shadow-core --features crypt
- run: cargo test --target x86_64-unknown-linux-musl -p uu_shadow_core --features crypt
# `pam` must be refused on static musl, not silently produce a binary
# whose authentication path can never work.
- name: pam is rejected on static musl
run: |
if cargo check --target x86_64-unknown-linux-musl -p shadow-core --features pam 2>check.log; then
if cargo check --target x86_64-unknown-linux-musl -p uu_shadow_core --features pam 2>check.log; then
echo "::error::the pam feature built on static musl; the compile_error guard in shadow-core is gone"
exit 1
fi
Expand Down
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,14 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

### Changed

- The shared library crate is named `uu_shadow_core` in its manifest, which is
the name it was published under (0.2.1) and the only one it can be published
under: `shadow-core` on crates.io belongs to an unrelated project. Its Rust
name stays `shadow_core`, so no code changes; `cargo test -p` and the like
take the new package name

## [0.5.1] - 2026-09-15

### Fixed
Expand Down
17 changes: 17 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,23 @@ they all run as root. A green pipeline has shipped an archive that would not
start and another whose setuid tools no user could run; this is what catches
that.

### Publishing to crates.io

The crates are owned by @sylvestre on crates.io; publishing needs an owner's
token. The library is published as `uu_shadow_core` (its Rust name stays
`shadow_core`; `shadow-core` on crates.io is somebody else's crate). Order
matters, since each crate's dependencies must already be on the registry at
the same version:

1. `uu_shadow_core`
2. every `uu_<tool>` crate that depends only on it
3. `uu_vigr`, `uu_pwunconv`, `uu_grpconv`, `uu_grpunconv`, `uu_newgidmap`,
which each wrap another tool's crate
4. `uu_shadow`, the multicall binary, which depends on all of them

`cargo publish --dry-run -p uu_shadow_core` works from a checkout; the others
can only be dry-run once their dependencies are published.

### Linting

```shell
Expand Down
80 changes: 40 additions & 40 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ categories = ["command-line-utilities"]

[workspace.dependencies]
# Internal crates
shadow-core = { path = "src/shadow-core", version = "0.5.1" }
shadow-core = { package = "uu_shadow_core", path = "src/shadow-core", version = "0.5.1" }

# CLI
clap = { version = "4", features = ["wrap_help"] }
Expand Down Expand Up @@ -86,7 +86,7 @@ tempfile = "3"
[dependencies]
clap = { workspace = true }
clap_complete = { workspace = true, optional = true }
shadow-core = { path = "src/shadow-core", version = "0.5.1" }
shadow-core = { package = "uu_shadow_core", path = "src/shadow-core", version = "0.5.1" }
rustix = { workspace = true }

# Tool crates (optional, enabled by features)
Expand Down Expand Up @@ -178,7 +178,7 @@ userdel = { version = "0.5.1", package = "uu_userdel", path = "src/uu/userdel" }
usermod = { version = "0.5.1", package = "uu_usermod", path = "src/uu/usermod" }
pwck = { version = "0.5.1", package = "uu_pwck", path = "src/uu/pwck" }
grpck = { version = "0.5.1", package = "uu_grpck", path = "src/uu/grpck" }
shadow-core = { path = "src/shadow-core", version = "0.5.1" }
shadow-core = { package = "uu_shadow_core", path = "src/shadow-core", version = "0.5.1" }
rustix = { workspace = true }
tempfile = { workspace = true }

Expand Down
2 changes: 1 addition & 1 deletion fuzz/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ cargo-fuzz = true
[dependencies]
libfuzzer-sys = "0.4"
# The record parsers are no longer behind features; only linkage is.
shadow-core = { path = "../src/shadow-core" }
shadow-core = { package = "uu_shadow_core", path = "../src/shadow-core" }
tempfile = "3"

[workspace]
Expand Down
Loading