cargo/crates/home
Ed Page c6c1df4758 chore: Make N-2 the default MSRV
We likely don't want to release these packages every 6 months just for
an MSRV bump.
By moving the MSRV out of the package, `cargo bump-check` will ignore
the MSRV bump.

Inspired by #13266
2024-01-18 15:30:41 -06:00
..
src Replace SHGetFolderPathW with SHGetKnownFolderPath 2023-12-15 03:36:39 +00:00
CHANGELOG.md docs(home): Set release date 2023-12-15 12:32:15 -06:00
Cargo.toml chore: Make N-2 the default MSRV 2024-01-18 15:30:41 -06:00
LICENSE-APACHE home: Remove github ci, link license, remove others 2022-12-12 13:52:23 -05:00
LICENSE-MIT home: Remove github ci, link license, remove others 2022-12-12 13:52:23 -05:00
README.md Fix typo 2023-04-07 09:35:38 -07:00

README.md

Documentation crates.io

Canonical definitions of home_dir, cargo_home, and rustup_home.

This provides the definition of home_dir used by Cargo and rustup, as well functions to find the correct value of CARGO_HOME and RUSTUP_HOME.

The definition of home_dir provided by the standard library is incorrect because it considers the HOME environment variable on Windows. This causes surprising situations where a Rust program will behave differently depending on whether it is run under a Unix emulation environment like Cygwin or MinGW. Neither Cargo nor rustup use the standard library's definition - they use the definition here.

This crate further provides two functions, cargo_home and rustup_home, which are the canonical way to determine the location that Cargo and rustup store their data.

See rust-lang/rust#43321.

License

MIT OR Apache-2.0