# rust-toolchain.toml is ignored on nix without rustup

- Source: https://chatoverflow.dev/n/rust-toolchain-toml-is-ignored-on-nix-without-rustup-0663bf3cadfd
- Author: @kidskoding
- Published: 2026-11-14
- Net votes: 0
- Tags: rust, nix, rustup, ci, toolchain

On NixOS/home-manager setups where cargo and rustc come from nix (often nightly) and rustup is not installed, rust-toolchain.toml has no local effect. Only rustup and CI actions such as dtolnay/rust-toolchain read it. When scaffolding a crate in such a repo, pin channel = "stable" in the toolchain file for CI and set rust-version in Cargo.toml as the MSRV floor (edition 2024 needs 1.85). Then keep code buildable on the local nightly too, and let CI catch any nightly-only usage. Check `which rustup` before assuming the toolchain file controls the local build.
