Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

install.root is not properly followed #258

Open
Skgland opened this issue May 8, 2024 · 2 comments
Open

install.root is not properly followed #258

Skgland opened this issue May 8, 2024 · 2 comments

Comments

@Skgland
Copy link

Skgland commented May 8, 2024

I believe #23 is (partially) broken again.
install.root Cargo config value appears to not be handled properly.

When I run cargo install-update -a it finds the packages to update (so it searches the .crates.toml/.crates2.json in the right place), but then it installes the updates into ~/.cargo/bin for some reason.

PS C:\Users\Bennet> cargo install-update --version
cargo-install-update 13.4.0
PS C:\Users\Bennet> cargo install-update --all
    Polling registry 'https://index.crates.io/'............

Package       Installed  Latest                               Needs update
cargo-audit   v0.18.3    v0.20.0                              Yes
cargo-deny    v0.14.3    v0.14.23                             Yes
flamegraph    v0.6.4     v0.6.5                               Yes
just          v1.16.0    v1.25.2                              Yes
biodiff       v1.2.1     v1.2.1                               No
cargo-cache   v0.8.3     v0.8.3                               No
cargo-edit    v0.12.2    v0.12.2                              No
cargo-msrv    v0.15.1    v0.15.1 (v0.16.0-beta.20 available)  No
cargo-update  v13.4.0    v13.4.0                              No
cbindgen      v0.26.0    v0.26.0                              No
diskonaut     v0.11.0    v0.11.0                              No
ripgrep       v14.1.0    v14.1.0                              No

Updating cargo-audit
    Updating crates.io index
  Installing cargo-audit v0.20.0
    Updating crates.io index
<!-- SNIP -->
   Compiling cargo-audit v0.20.0
    Finished release [optimized] target(s) in 2m 04s
  Installing C:\Users\Bennet\.cargo\bin\cargo-audit.exe
   Installed package `cargo-audit v0.20.0` (executable `cargo-audit.exe`)
<!-- SNIP -->

While cargo install cargo-audit works correctly

PS C:\Users\Bennet> cargo install cargo-audit
    Updating crates.io index
  Installing cargo-audit v0.20.0
    Updating crates.io index
<!-- SNIP -->
   Compiling cargo-audit v0.20.0
    Finished release [optimized] target(s) in 2m 03s
   Replacing \\NAS\Some\Path\bin\cargo-audit.exe
    Replaced package `cargo-audit v0.18.3` with `cargo-audit v0.20.0` (executable `cargo-audit.exe`)
@nabijaczleweli
Copy link
Owner

and, pray tell, what would that config be?

@Skgland
Copy link
Author

Skgland commented May 9, 2024

In C:\Users\Bennet\.cargo\config.toml

[install]
root = "\\\\NAS\\Some\\Path"

Which should correspond to %USERPROFILE%\.cargo\config.toml listed in https://doc.rust-lang.org/cargo/reference/config.html#hierarchical-structure

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

No branches or pull requests

2 participants