Skip to content

Conversation

cakebaker
Copy link
Contributor

Fixes #7427

@cakebaker cakebaker force-pushed the all_adapt_version_string branch from 356a847 to 1855317 Compare March 13, 2025 09:56
@sylvestre
Copy link
Contributor

can we centralize the string somewhere ? to be able to update it in a single place

Copy link

GNU testsuite comparison:

GNU test failed: tests/misc/tee. tests/misc/tee is passing on 'main'. Maybe you have to rebase?
Skip an intermittent issue tests/timeout/timeout (fails in this run but passes in the 'main' branch)

@cakebaker cakebaker marked this pull request as draft March 15, 2025 06:15
@cakebaker cakebaker force-pushed the all_adapt_version_string branch 2 times, most recently from 100922c to 5872a52 Compare March 15, 2025 14:58
@cakebaker cakebaker force-pushed the all_adapt_version_string branch from 5872a52 to 75260a5 Compare March 15, 2025 15:03
Copy link

GNU testsuite comparison:

Skip an intermittent issue tests/misc/stdbuf (fails in this run but passes in the 'main' branch)

@cakebaker cakebaker marked this pull request as ready for review March 15, 2025 15:31
@cakebaker
Copy link
Contributor Author

Ok, I found a solution: I moved the string to .cargo/config.toml and added our own crate_version macro to uucore.

@cakebaker cakebaker requested a review from sylvestre March 15, 2025 15:38
@sylvestre sylvestre merged commit 0b228cf into uutils:main Mar 15, 2025
67 checks passed
@cakebaker cakebaker deleted the all_adapt_version_string branch March 15, 2025 16:35
@Ecordonnier
Copy link
Contributor

Ecordonnier commented May 29, 2025

FYI this breaks out-of-tree builds, where .cargo/config.toml does not get used. I'll send a fix.
E.g.:

$ mkdir test-uutils
test-uutils$ cargo build --manifest-path=../coreutils/Cargo.toml
...
error: environment variable `PROJECT_NAME_FOR_VERSION_STRING` not defined at compile time
   --> src/uu/base32/src/base_common.rs:107:18
    |
107 |         .version(uucore::crate_version!())
...

@cakebaker
Copy link
Contributor Author

See also: #7992

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

--version should provide uutils-specific identifier
3 participants