commit b613911f469bf281e6b6b7386fd3fd517944e2ec Author: Tristan Daniƫl Maat Date: Wed Dec 2 20:30:51 2020 +0000 Add nix env diff --git a/.envrc b/.envrc new file mode 100644 index 0000000..1d953f4 --- /dev/null +++ b/.envrc @@ -0,0 +1 @@ +use nix diff --git a/shell.nix b/shell.nix new file mode 100644 index 0000000..232285d --- /dev/null +++ b/shell.nix @@ -0,0 +1,17 @@ +let + mozilla = import (builtins.fetchTarball https://github.com/mozilla/nixpkgs-mozilla/archive/master.tar.gz); + pkgs = import { overlays = [ mozilla ]; }; + rustChannel = pkgs.latest.rustChannels.stable; +in + +with pkgs; + +mkShell { + buildInputs = [ + rustChannel.rust + ]; + + shellHook = '' + export RUST_SRC_PATH="${rustChannel.rust-src}/lib/rustlib/src/rust/library" + ''; +}