X-Git-Url: https://git.patrickod.com/noisetor.ansible/refs/?a=blobdiff_plain;f=shell.nix;fp=shell.nix;h=19b7c155433337b1d8dfda6b9e6407720a39aaa8;hb=ae7e9009c24193d06daa77bdfcde9caeb37053e4;hp=0000000000000000000000000000000000000000;hpb=563efa0d02de05a2f3a35ea2a9d689df4c8cd55b;p=keywing-rs.git diff --git a/shell.nix b/shell.nix new file mode 100644 index 0000000..19b7c15 --- /dev/null +++ b/shell.nix @@ -0,0 +1,38 @@ +let + rust-version = "1.46.0"; + + nixpkgs = fetchGit { + url = "https://github.com/patrickod/nixpkgs.git"; + rev = "8bb6ca5f0a93bb0b9264b50a8c56431c7c7cc591"; + ref = "personal"; + }; + + mozilla-overlay = + import (builtins.fetchTarball https://github.com/mozilla/nixpkgs-mozilla/archive/master.tar.gz); + + pkgs = import nixpkgs { + overlays = [ mozilla-overlay ]; + }; + + targets = [ + "x86_64-unknown-linux-gnu" + "thumbv7em-none-eabihf" + ]; + +in + pkgs.mkShell { + name = "rust-dev"; + nativeBuildInputs = with pkgs; [ + (rustChannels.stable.rust.override { + targets = targets; + extensions = [ + "rust-src" + "rust-analysis" + "rls-preview" + ]; + }) + gcc-arm-embedded + cargo-hf2 + rustup + ]; + }