Skip to content

Commit

Permalink
Add env var for rust-analyzer
Browse files Browse the repository at this point in the history
  • Loading branch information
lucperkins committed Jul 20, 2024
1 parent 7f2ef8c commit ff2c36b
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
5 changes: 5 additions & 0 deletions rust-toolchain/flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,11 @@
cargo-watch
rust-analyzer
];

env = {
# Required by rust-analyzer
RUST_SRC_PATH = "${pkgs.rustToolchain}/lib/rustlib/src/rust/library";
};
};
});
};
Expand Down
5 changes: 5 additions & 0 deletions rust/flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,11 @@
cargo-watch
rust-analyzer
];

env = {
# Required by rust-analyzer
RUST_SRC_PATH = "${pkgs.rustToolchain}/lib/rustlib/src/rust/library";
};
};
});
};
Expand Down

0 comments on commit ff2c36b

Please sign in to comment.