From ddc4f287551970446d7f3a3d789590447f698775 Mon Sep 17 00:00:00 2001 From: Luc Perkins Date: Sun, 28 Aug 2022 16:26:43 +0300 Subject: [PATCH 1/4] Update cargo deps --- rust/flake.nix | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/rust/flake.nix b/rust/flake.nix index 6650643..ada4164 100644 --- a/rust/flake.nix +++ b/rust/flake.nix @@ -40,9 +40,8 @@ rustToolchain openssl pkg-config - cargo-audit cargo-deny - cargo-cross + cargo-edit rust-analyzer ] ++ pkgs.lib.optionals (pkgs.stdenv.isLinux) (with pkgs; [ cargo-watch ]); # Currently broken on macOS From c4a5d837e48807025580221504a86435913c3570 Mon Sep 17 00:00:00 2001 From: Luc Perkins Date: Wed, 12 Oct 2022 16:42:34 -0500 Subject: [PATCH 2/4] Update flakes --- clojure/flake.lock | 6 +++--- clojure/flake.nix | 2 +- cue/flake.lock | 6 +++--- cue/flake.nix | 2 +- dhall/flake.lock | 6 +++--- dhall/flake.nix | 2 +- elixir/flake.lock | 6 +++--- elixir/flake.nix | 2 +- elm/flake.lock | 6 +++--- elm/flake.nix | 2 +- gleam/flake.lock | 6 +++--- gleam/flake.nix | 2 +- go/flake.lock | 6 +++--- go/flake.nix | 4 ++-- hashi/flake.lock | 6 +++--- hashi/flake.nix | 2 +- haskell/flake.lock | 6 +++--- haskell/flake.nix | 2 +- java/flake.lock | 6 +++--- java/flake.nix | 2 +- kotlin/flake.lock | 6 +++--- kotlin/flake.nix | 2 +- nickel/flake.lock | 6 +++--- nickel/flake.nix | 2 +- nix/.envrc | 1 - nix/flake.lock | 6 +++--- nix/flake.nix | 2 +- node/flake.lock | 6 +++--- node/flake.nix | 2 +- ocaml/flake.lock | 6 +++--- ocaml/flake.nix | 2 +- opa/flake.lock | 6 +++--- opa/flake.nix | 2 +- protobuf/flake.lock | 6 +++--- protobuf/flake.nix | 2 +- python/flake.lock | 18 +++++++++--------- python/flake.nix | 2 +- ruby/flake.lock | 6 +++--- ruby/flake.nix | 2 +- rust/flake.lock | 24 ++++++++++++------------ rust/flake.nix | 2 +- scala/flake.lock | 6 +++--- scala/flake.nix | 2 +- zig/flake.lock | 6 +++--- zig/flake.nix | 2 +- 45 files changed, 104 insertions(+), 105 deletions(-) diff --git a/clojure/flake.lock b/clojure/flake.lock index 316c9af..d6fab38 100644 --- a/clojure/flake.lock +++ b/clojure/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665607107, + "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", "type": "github" }, "original": { diff --git a/clojure/flake.nix b/clojure/flake.nix index e440944..f984a9e 100644 --- a/clojure/flake.nix +++ b/clojure/flake.nix @@ -32,7 +32,7 @@ pkgs = import nixpkgs { inherit overlays system; }; in { - devShell = pkgs.mkShell { + devShells.default = pkgs.mkShell { buildInputs = with pkgs; [ boot clojure leiningen ]; shellHook = '' diff --git a/cue/flake.lock b/cue/flake.lock index 316c9af..d6fab38 100644 --- a/cue/flake.lock +++ b/cue/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665607107, + "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", "type": "github" }, "original": { diff --git a/cue/flake.nix b/cue/flake.nix index ee28e0f..726ba64 100644 --- a/cue/flake.nix +++ b/cue/flake.nix @@ -17,7 +17,7 @@ pkgs = import nixpkgs { inherit system; }; in { - devShell = pkgs.mkShell { + devShells.default = pkgs.mkShell { buildInputs = with pkgs; [ cue ]; shellHook = '' diff --git a/dhall/flake.lock b/dhall/flake.lock index 316c9af..d6fab38 100644 --- a/dhall/flake.lock +++ b/dhall/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665607107, + "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", "type": "github" }, "original": { diff --git a/dhall/flake.nix b/dhall/flake.nix index c6d7813..e955504 100644 --- a/dhall/flake.nix +++ b/dhall/flake.nix @@ -33,7 +33,7 @@ ] ++ pkgs.lib.optionals (pkgs.stdenv.isLinux) (mkDhallTools [ "csv" "text" ]); # Linux only in { - devShell = pkgs.mkShell { + devShells.default = pkgs.mkShell { buildInputs = (with pkgs; [ dhall ]) ++ dhallTools; shellHook = '' diff --git a/elixir/flake.lock b/elixir/flake.lock index 316c9af..d6fab38 100644 --- a/elixir/flake.lock +++ b/elixir/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665607107, + "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", "type": "github" }, "original": { diff --git a/elixir/flake.nix b/elixir/flake.nix index a6a2ece..49f3df7 100644 --- a/elixir/flake.nix +++ b/elixir/flake.nix @@ -17,7 +17,7 @@ pkgs = import nixpkgs { inherit system; }; in { - devShell = pkgs.mkShell { + devShells.default = pkgs.mkShell { buildInputs = (with pkgs; [ elixir ]) ++ pkgs.lib.optionals (pkgs.stdenv.isLinux) (with pkgs; [ gigalixir inotify-tools libnotify ]) ++ # Linux only pkgs.lib.optionals (pkgs.stdenv.isDarwin) (with pkgs; [ terminal-notifier ]) ++ # macOS only diff --git a/elm/flake.lock b/elm/flake.lock index 316c9af..d6fab38 100644 --- a/elm/flake.lock +++ b/elm/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665607107, + "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", "type": "github" }, "original": { diff --git a/elm/flake.nix b/elm/flake.nix index a2cabbe..5e8b56a 100644 --- a/elm/flake.nix +++ b/elm/flake.nix @@ -17,7 +17,7 @@ pkgs = import nixpkgs { inherit system; }; in { - devShell = pkgs.mkShell { + devShells.default = pkgs.mkShell { buildInputs = (with pkgs.elmPackages; [ elm ]) ++ (with pkgs; [ elm2nix ]); shellHook = with pkgs.elmPackages; '' diff --git a/gleam/flake.lock b/gleam/flake.lock index 316c9af..d6fab38 100644 --- a/gleam/flake.lock +++ b/gleam/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665607107, + "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", "type": "github" }, "original": { diff --git a/gleam/flake.nix b/gleam/flake.nix index 093ccdc..0f1f659 100644 --- a/gleam/flake.nix +++ b/gleam/flake.nix @@ -17,7 +17,7 @@ pkgs = import nixpkgs { inherit system; }; in { - devShell = pkgs.mkShell { + devShells.default = pkgs.mkShell { buildInputs = with pkgs; [ gleam ]; shellHook = '' diff --git a/go/flake.lock b/go/flake.lock index 316c9af..d6fab38 100644 --- a/go/flake.lock +++ b/go/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665607107, + "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", "type": "github" }, "original": { diff --git a/go/flake.nix b/go/flake.nix index ac43480..ab4d6c2 100644 --- a/go/flake.nix +++ b/go/flake.nix @@ -19,9 +19,9 @@ pkgs = import nixpkgs { inherit overlays system; }; in { - devShell = pkgs.mkShellNoCC { + devShells.default = pkgs.mkShellNoCC { buildInputs = with pkgs; [ - # go 1.17.1 (specified by overlay) + # go 1.19 (specified by overlay) go # goimports, godoc, etc. diff --git a/hashi/flake.lock b/hashi/flake.lock index 316c9af..d6fab38 100644 --- a/hashi/flake.lock +++ b/hashi/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665607107, + "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", "type": "github" }, "original": { diff --git a/hashi/flake.nix b/hashi/flake.nix index 5da6b95..5040526 100644 --- a/hashi/flake.nix +++ b/hashi/flake.nix @@ -18,7 +18,7 @@ pkgs = import nixpkgs { inherit system; }; in { - devShell = pkgs.mkShell { + devShells.default = pkgs.mkShell { buildInputs = with pkgs; [ packer terraform diff --git a/haskell/flake.lock b/haskell/flake.lock index 316c9af..d6fab38 100644 --- a/haskell/flake.lock +++ b/haskell/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665607107, + "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", "type": "github" }, "original": { diff --git a/haskell/flake.nix b/haskell/flake.nix index 505b5c6..63ce1d2 100644 --- a/haskell/flake.nix +++ b/haskell/flake.nix @@ -17,7 +17,7 @@ pkgs = import nixpkgs { inherit system; }; in { - devShell = pkgs.mkShell { + devShells.default = pkgs.mkShell { buildInputs = with pkgs; [ cabal-install ghc ]; shellHook = with pkgs; '' diff --git a/java/flake.lock b/java/flake.lock index 316c9af..d6fab38 100644 --- a/java/flake.lock +++ b/java/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665607107, + "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", "type": "github" }, "original": { diff --git a/java/flake.nix b/java/flake.nix index bb4fba5..1ad6a15 100644 --- a/java/flake.nix +++ b/java/flake.nix @@ -31,7 +31,7 @@ pkgs = import nixpkgs { inherit overlays system; }; in { - devShell = pkgs.mkShell { + devShells.default = pkgs.mkShell { buildInputs = with pkgs; [ gradle jdk maven ]; shellHook = '' diff --git a/kotlin/flake.lock b/kotlin/flake.lock index 316c9af..d6fab38 100644 --- a/kotlin/flake.lock +++ b/kotlin/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665607107, + "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", "type": "github" }, "original": { diff --git a/kotlin/flake.nix b/kotlin/flake.nix index 488a2ee..7daba80 100644 --- a/kotlin/flake.nix +++ b/kotlin/flake.nix @@ -31,7 +31,7 @@ pkgs = import nixpkgs { inherit overlays system; }; in { - devShell = pkgs.mkShell { + devShells.default = pkgs.mkShell { buildInputs = with pkgs; [ kotlin gradle gcc ncurses patchelf zlib ]; shellHook = '' diff --git a/nickel/flake.lock b/nickel/flake.lock index 316c9af..d6fab38 100644 --- a/nickel/flake.lock +++ b/nickel/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665607107, + "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", "type": "github" }, "original": { diff --git a/nickel/flake.nix b/nickel/flake.nix index d7157ff..422f2a8 100644 --- a/nickel/flake.nix +++ b/nickel/flake.nix @@ -17,7 +17,7 @@ pkgs = import nixpkgs { inherit system; }; in { - devShell = pkgs.mkShell { + devShells.default = pkgs.mkShell { buildInputs = with pkgs; [ nickel ]; shellHook = '' diff --git a/nix/.envrc b/nix/.envrc index 03f8b73..a5dbbcb 100644 --- a/nix/.envrc +++ b/nix/.envrc @@ -1,2 +1 @@ use flake . -use flake . diff --git a/nix/flake.lock b/nix/flake.lock index 316c9af..d6fab38 100644 --- a/nix/flake.lock +++ b/nix/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665607107, + "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", "type": "github" }, "original": { diff --git a/nix/flake.nix b/nix/flake.nix index 6c931e9..afda172 100644 --- a/nix/flake.nix +++ b/nix/flake.nix @@ -17,7 +17,7 @@ pkgs = import nixpkgs { inherit system; }; in { - devShell = { + devShells.default = pkgs.mkShell { buildInputs = with pkgs; [ cachix lorri diff --git a/node/flake.lock b/node/flake.lock index 316c9af..d6fab38 100644 --- a/node/flake.lock +++ b/node/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665607107, + "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", "type": "github" }, "original": { diff --git a/node/flake.nix b/node/flake.nix index 7fba182..8c92567 100644 --- a/node/flake.nix +++ b/node/flake.nix @@ -24,7 +24,7 @@ pkgs = import nixpkgs { inherit overlays system; }; in { - devShell = pkgs.mkShell { + devShells.default = pkgs.mkShell { buildInputs = with pkgs; [ node2nix nodejs pnpm yarn ]; shellHook = '' diff --git a/ocaml/flake.lock b/ocaml/flake.lock index 316c9af..d6fab38 100644 --- a/ocaml/flake.lock +++ b/ocaml/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665607107, + "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", "type": "github" }, "original": { diff --git a/ocaml/flake.nix b/ocaml/flake.nix index 800e6d9..f9cacb0 100644 --- a/ocaml/flake.nix +++ b/ocaml/flake.nix @@ -17,7 +17,7 @@ pkgs = import nixpkgs { inherit system; }; in { - devShell = pkgs.mkShell { + devShells.default = pkgs.mkShell { buildInputs = with pkgs; [ ocaml ocamlformat ] ++ (with pkgs.ocamlPackages; [ dune_3 odoc ]); diff --git a/opa/flake.lock b/opa/flake.lock index 316c9af..d6fab38 100644 --- a/opa/flake.lock +++ b/opa/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665607107, + "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", "type": "github" }, "original": { diff --git a/opa/flake.nix b/opa/flake.nix index 4d6599b..ca4af7b 100644 --- a/opa/flake.nix +++ b/opa/flake.nix @@ -17,7 +17,7 @@ pkgs = import nixpkgs { inherit system; }; in { - devShell = pkgs.mkShell { + devShells.default = pkgs.mkShell { buildInputs = with pkgs; [ open-policy-agent conftest ]; shellHook = '' diff --git a/protobuf/flake.lock b/protobuf/flake.lock index 316c9af..d6fab38 100644 --- a/protobuf/flake.lock +++ b/protobuf/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665607107, + "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", "type": "github" }, "original": { diff --git a/protobuf/flake.nix b/protobuf/flake.nix index b4bb3bf..24cf3b4 100644 --- a/protobuf/flake.nix +++ b/protobuf/flake.nix @@ -16,7 +16,7 @@ pkgs = import nixpkgs { inherit system; }; in { - devShell = pkgs.mkShell { + devShells.default = pkgs.mkShell { buildInputs = with pkgs; [ buf protobuf ]; shellHook = with pkgs; '' diff --git a/python/flake.lock b/python/flake.lock index c2bbc48..37375c6 100644 --- a/python/flake.lock +++ b/python/flake.lock @@ -37,11 +37,11 @@ "pypi-deps-db": "pypi-deps-db" }, "locked": { - "lastModified": 1660767432, - "narHash": "sha256-aFZSd2aAO10IaVLCaff+oXsibm+m2BDlrxapEesW14E=", + "lastModified": 1662635943, + "narHash": "sha256-1OBBlBzZ894or8eHZjyADOMnGH89pPUKYGVVS5rwW/0=", "owner": "DavHau", "repo": "mach-nix", - "rev": "b5614640bc3379408d90db9e375b47345fbc21eb", + "rev": "65266b5cc867fec2cb6a25409dd7cd12251f6107", "type": "github" }, "original": { @@ -67,11 +67,11 @@ }, "nixpkgs_2": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665607107, + "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", "type": "github" }, "original": { @@ -83,11 +83,11 @@ "pypi-deps-db": { "flake": false, "locked": { - "lastModified": 1643877077, - "narHash": "sha256-jv8pIvRFTP919GybOxXE5TfOkrjTbdo9QiCO1TD3ZaY=", + "lastModified": 1661155889, + "narHash": "sha256-t00mBTZhmZBT4jteO6pJbU0wyRS6/ep4pKmQNeztEms=", "owner": "DavHau", "repo": "pypi-deps-db", - "rev": "da53397f0b782b0b18deb72ef8e0fb5aa7c98aa3", + "rev": "49c620f3de2b557c9d5c44f58a00fee59f27d1b0", "type": "github" }, "original": { diff --git a/python/flake.nix b/python/flake.nix index 8cd5c1a..4027d74 100644 --- a/python/flake.nix +++ b/python/flake.nix @@ -25,7 +25,7 @@ pkgs = import nixpkgs { inherit overlays system; }; in { - devShell = pkgs.mkShell { + devShells.default = pkgs.mkShell { buildInputs = with pkgs; [ python machNix virtualenv ] ++ (with pkgs.python311Packages; [ pip ]); diff --git a/ruby/flake.lock b/ruby/flake.lock index 316c9af..d6fab38 100644 --- a/ruby/flake.lock +++ b/ruby/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665607107, + "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", "type": "github" }, "original": { diff --git a/ruby/flake.nix b/ruby/flake.nix index 91d97aa..5eb2131 100644 --- a/ruby/flake.nix +++ b/ruby/flake.nix @@ -21,7 +21,7 @@ pkgs = import nixpkgs { inherit overlays system; }; in { - devShell = pkgs.mkShell { + devShells.default = pkgs.mkShell { buildInputs = with pkgs; [ ruby ]; shellHook = '' diff --git a/rust/flake.lock b/rust/flake.lock index 7317610..85f0a71 100644 --- a/rust/flake.lock +++ b/rust/flake.lock @@ -17,11 +17,11 @@ }, "flake-utils_2": { "locked": { - "lastModified": 1656928814, - "narHash": "sha256-RIFfgBuKz6Hp89yRr7+NR5tzIAbn52h8vT6vXkYjZoM=", + "lastModified": 1659877975, + "narHash": "sha256-zllb8aq3YO3h8B/U0/J1WBgAL8EX5yWf5pMj3G0NAmc=", "owner": "numtide", "repo": "flake-utils", - "rev": "7e2a3b3dfd9af950a856d66b0a7d01e3c18aa249", + "rev": "c0e246b9b83f637f4681389ecabcb2681b4f3af0", "type": "github" }, "original": { @@ -32,11 +32,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665607107, + "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", "type": "github" }, "original": { @@ -47,11 +47,11 @@ }, "nixpkgs_2": { "locked": { - "lastModified": 1659102345, - "narHash": "sha256-Vbzlz254EMZvn28BhpN8JOi5EuKqnHZ3ujFYgFcSGvk=", + "lastModified": 1665296151, + "narHash": "sha256-uOB0oxqxN9K7XGF1hcnY+PQnlQJ+3bP2vCn/+Ru/bbc=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "11b60e4f80d87794a2a4a8a256391b37c59a1ea7", + "rev": "14ccaaedd95a488dd7ae142757884d8e125b3363", "type": "github" }, "original": { @@ -74,11 +74,11 @@ "nixpkgs": "nixpkgs_2" }, "locked": { - "lastModified": 1661136859, - "narHash": "sha256-o3y1elFGRs/9kqaIeziAnTy9lIWA6VHtQfq0ARRVO2A=", + "lastModified": 1665543630, + "narHash": "sha256-tt3EmBcNCER8G9mCmYmPel/KwMlkIP56un33ArE65eo=", "owner": "oxalica", "repo": "rust-overlay", - "rev": "6d1418192be90968acfa25e7d7b089e246eb15c4", + "rev": "8c727f07aa0ce5b618a3c653da75ace830485b21", "type": "github" }, "original": { diff --git a/rust/flake.nix b/rust/flake.nix index ada4164..4a2362d 100644 --- a/rust/flake.nix +++ b/rust/flake.nix @@ -35,7 +35,7 @@ pkgs = import nixpkgs { inherit system overlays; }; in { - devShell = pkgs.mkShell { + devShells.default = pkgs.mkShell { nativeBuildInputs = with pkgs; [ rustToolchain openssl diff --git a/scala/flake.lock b/scala/flake.lock index 316c9af..d6fab38 100644 --- a/scala/flake.lock +++ b/scala/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665607107, + "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", "type": "github" }, "original": { diff --git a/scala/flake.nix b/scala/flake.nix index 76b8129..913ac41 100644 --- a/scala/flake.nix +++ b/scala/flake.nix @@ -31,7 +31,7 @@ pkgs = import nixpkgs { inherit overlays system; }; in { - devShell = pkgs.mkShell { + devShells.default = pkgs.mkShell { buildInputs = with pkgs; [ scala sbt coursier ]; shellHook = '' diff --git a/zig/flake.lock b/zig/flake.lock index 316c9af..d6fab38 100644 --- a/zig/flake.lock +++ b/zig/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665607107, + "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", "type": "github" }, "original": { diff --git a/zig/flake.nix b/zig/flake.nix index 7ab0ba9..99af3fa 100644 --- a/zig/flake.nix +++ b/zig/flake.nix @@ -17,7 +17,7 @@ pkgs = import nixpkgs { inherit system; }; in { - devShell = pkgs.mkShell { + devShells.default = pkgs.mkShell { buildInputs = with pkgs; [ zig ]; shellHook = '' From 20b5b176c1e736e7eef260db232a13f888b92dfd Mon Sep 17 00:00:00 2001 From: Luc Perkins Date: Thu, 20 Oct 2022 16:14:56 +0200 Subject: [PATCH 3/4] Add rust-toolchain template --- clojure/flake.lock | 6 +- cue/flake.lock | 6 +- dhall/flake.lock | 6 +- elixir/flake.lock | 6 +- elm/flake.lock | 6 +- flake.nix | 10 +++- gleam/flake.lock | 6 +- go/flake.lock | 6 +- hashi/flake.lock | 6 +- haskell/flake.lock | 6 +- java/flake.lock | 6 +- kotlin/flake.lock | 6 +- nickel/flake.lock | 6 +- nim/flake.lock | 6 +- nix/flake.lock | 6 +- node/flake.lock | 6 +- ocaml/flake.lock | 6 +- opa/flake.lock | 6 +- protobuf/flake.lock | 6 +- python/flake.lock | 6 +- ruby/flake.lock | 6 +- rust-toolchain/.envrc | 1 + rust-toolchain/flake.lock | 93 ++++++++++++++++++++++++++++++ rust-toolchain/flake.nix | 44 ++++++++++++++ rust-toolchain/rust-toolchain.toml | 2 + rust/flake.lock | 12 ++-- scala/flake.lock | 6 +- zig/flake.lock | 6 +- 28 files changed, 221 insertions(+), 73 deletions(-) create mode 100644 rust-toolchain/.envrc create mode 100644 rust-toolchain/flake.lock create mode 100644 rust-toolchain/flake.nix create mode 100644 rust-toolchain/rust-toolchain.toml diff --git a/clojure/flake.lock b/clojure/flake.lock index d6fab38..48974ad 100644 --- a/clojure/flake.lock +++ b/clojure/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1665607107, - "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { diff --git a/cue/flake.lock b/cue/flake.lock index d6fab38..48974ad 100644 --- a/cue/flake.lock +++ b/cue/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1665607107, - "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { diff --git a/dhall/flake.lock b/dhall/flake.lock index d6fab38..48974ad 100644 --- a/dhall/flake.lock +++ b/dhall/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1665607107, - "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { diff --git a/elixir/flake.lock b/elixir/flake.lock index d6fab38..48974ad 100644 --- a/elixir/flake.lock +++ b/elixir/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1665607107, - "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { diff --git a/elm/flake.lock b/elm/flake.lock index d6fab38..48974ad 100644 --- a/elm/flake.lock +++ b/elm/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1665607107, - "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { diff --git a/flake.nix b/flake.nix index 38055b9..f422940 100644 --- a/flake.nix +++ b/flake.nix @@ -9,7 +9,7 @@ outputs = { self, flake-utils, nixpkgs }: { - templates = { + templates = rec { cue = { path = ./cue; description = "Cue development environment"; @@ -105,6 +105,11 @@ description = "Rust development environment"; }; + rust-toolchain = { + path = ./rust-toolchain; + description = "Rust development environment with Rust version defined by a rust-toolchain.toml file"; + }; + scala = { path = ./scala; description = "Scala development environment"; @@ -114,6 +119,9 @@ path = ./zig; description = "Zig development environment"; }; + + # Aliases + rt = rust-toolchain; }; } // flake-utils.lib.eachDefaultSystem (system: let diff --git a/gleam/flake.lock b/gleam/flake.lock index d6fab38..48974ad 100644 --- a/gleam/flake.lock +++ b/gleam/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1665607107, - "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { diff --git a/go/flake.lock b/go/flake.lock index d6fab38..48974ad 100644 --- a/go/flake.lock +++ b/go/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1665607107, - "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { diff --git a/hashi/flake.lock b/hashi/flake.lock index d6fab38..48974ad 100644 --- a/hashi/flake.lock +++ b/hashi/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1665607107, - "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { diff --git a/haskell/flake.lock b/haskell/flake.lock index d6fab38..48974ad 100644 --- a/haskell/flake.lock +++ b/haskell/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1665607107, - "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { diff --git a/java/flake.lock b/java/flake.lock index d6fab38..48974ad 100644 --- a/java/flake.lock +++ b/java/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1665607107, - "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { diff --git a/kotlin/flake.lock b/kotlin/flake.lock index d6fab38..48974ad 100644 --- a/kotlin/flake.lock +++ b/kotlin/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1665607107, - "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { diff --git a/nickel/flake.lock b/nickel/flake.lock index d6fab38..48974ad 100644 --- a/nickel/flake.lock +++ b/nickel/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1665607107, - "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { diff --git a/nim/flake.lock b/nim/flake.lock index 316c9af..48974ad 100644 --- a/nim/flake.lock +++ b/nim/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1661178095, - "narHash": "sha256-VP8KoVbqHT7dihr8XES0fM1SmuOxQGyRP85MMDTSEf0=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2a38cb03b8f5badfb70bfc2acb3151ed9609e38", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { diff --git a/nix/flake.lock b/nix/flake.lock index d6fab38..48974ad 100644 --- a/nix/flake.lock +++ b/nix/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1665607107, - "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { diff --git a/node/flake.lock b/node/flake.lock index d6fab38..48974ad 100644 --- a/node/flake.lock +++ b/node/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1665607107, - "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { diff --git a/ocaml/flake.lock b/ocaml/flake.lock index d6fab38..48974ad 100644 --- a/ocaml/flake.lock +++ b/ocaml/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1665607107, - "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { diff --git a/opa/flake.lock b/opa/flake.lock index d6fab38..48974ad 100644 --- a/opa/flake.lock +++ b/opa/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1665607107, - "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { diff --git a/protobuf/flake.lock b/protobuf/flake.lock index d6fab38..48974ad 100644 --- a/protobuf/flake.lock +++ b/protobuf/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1665607107, - "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { diff --git a/python/flake.lock b/python/flake.lock index 37375c6..d0a4e97 100644 --- a/python/flake.lock +++ b/python/flake.lock @@ -67,11 +67,11 @@ }, "nixpkgs_2": { "locked": { - "lastModified": 1665607107, - "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { diff --git a/ruby/flake.lock b/ruby/flake.lock index d6fab38..48974ad 100644 --- a/ruby/flake.lock +++ b/ruby/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1665607107, - "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { diff --git a/rust-toolchain/.envrc b/rust-toolchain/.envrc new file mode 100644 index 0000000..a5dbbcb --- /dev/null +++ b/rust-toolchain/.envrc @@ -0,0 +1 @@ +use flake . diff --git a/rust-toolchain/flake.lock b/rust-toolchain/flake.lock new file mode 100644 index 0000000..a17a36a --- /dev/null +++ b/rust-toolchain/flake.lock @@ -0,0 +1,93 @@ +{ + "nodes": { + "flake-utils": { + "locked": { + "lastModified": 1659877975, + "narHash": "sha256-zllb8aq3YO3h8B/U0/J1WBgAL8EX5yWf5pMj3G0NAmc=", + "owner": "numtide", + "repo": "flake-utils", + "rev": "c0e246b9b83f637f4681389ecabcb2681b4f3af0", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "flake-utils", + "type": "github" + } + }, + "flake-utils_2": { + "locked": { + "lastModified": 1659877975, + "narHash": "sha256-zllb8aq3YO3h8B/U0/J1WBgAL8EX5yWf5pMj3G0NAmc=", + "owner": "numtide", + "repo": "flake-utils", + "rev": "c0e246b9b83f637f4681389ecabcb2681b4f3af0", + "type": "github" + }, + "original": { + "owner": "numtide", + "repo": "flake-utils", + "type": "github" + } + }, + "nixpkgs": { + "locked": { + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", + "type": "github" + }, + "original": { + "owner": "NixOS", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs_2": { + "locked": { + "lastModified": 1665296151, + "narHash": "sha256-uOB0oxqxN9K7XGF1hcnY+PQnlQJ+3bP2vCn/+Ru/bbc=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "14ccaaedd95a488dd7ae142757884d8e125b3363", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixpkgs-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "root": { + "inputs": { + "flake-utils": "flake-utils", + "nixpkgs": "nixpkgs", + "rust-overlay": "rust-overlay" + } + }, + "rust-overlay": { + "inputs": { + "flake-utils": "flake-utils_2", + "nixpkgs": "nixpkgs_2" + }, + "locked": { + "lastModified": 1665630024, + "narHash": "sha256-xXfneoHz4h4JR58leKFoHIIapAffWlOL9HI37vwuspo=", + "owner": "oxalica", + "repo": "rust-overlay", + "rev": "73650741960a7422d1422f156f76211e576610c2", + "type": "github" + }, + "original": { + "owner": "oxalica", + "repo": "rust-overlay", + "type": "github" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/rust-toolchain/flake.nix b/rust-toolchain/flake.nix new file mode 100644 index 0000000..861112e --- /dev/null +++ b/rust-toolchain/flake.nix @@ -0,0 +1,44 @@ +{ + description = "A Nix-flake-based Rust development environment"; + + inputs = { + flake-utils.url = "github:numtide/flake-utils"; + nixpkgs.url = "github:NixOS/nixpkgs"; + rust-overlay.url = "github:oxalica/rust-overlay"; + }; + + outputs = + { self + , flake-utils + , nixpkgs + , rust-overlay + }: + + flake-utils.lib.eachDefaultSystem (system: + let + overlays = [ + (import rust-overlay) + (self: super: { + rustToolchain = super.rust-bin.fromRustupToolchainFile ./rust-toolchain.toml; + }) + ]; + + pkgs = import nixpkgs { inherit system overlays; }; + in + { + devShells.default = pkgs.mkShell { + nativeBuildInputs = with pkgs; [ + rustToolchain + openssl + pkg-config + cargo-deny + cargo-edit + rust-analyzer + ] ++ pkgs.lib.optionals (pkgs.stdenv.isLinux) (with pkgs; [ cargo-watch ]); # Currently broken on macOS + + shellHook = '' + ${pkgs.rustToolchain}/bin/cargo --version + ''; + }; + }); +} diff --git a/rust-toolchain/rust-toolchain.toml b/rust-toolchain/rust-toolchain.toml new file mode 100644 index 0000000..10add70 --- /dev/null +++ b/rust-toolchain/rust-toolchain.toml @@ -0,0 +1,2 @@ +[toolchain] +channel = "1.64.0" diff --git a/rust/flake.lock b/rust/flake.lock index 85f0a71..a17a36a 100644 --- a/rust/flake.lock +++ b/rust/flake.lock @@ -32,11 +32,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1665607107, - "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { @@ -74,11 +74,11 @@ "nixpkgs": "nixpkgs_2" }, "locked": { - "lastModified": 1665543630, - "narHash": "sha256-tt3EmBcNCER8G9mCmYmPel/KwMlkIP56un33ArE65eo=", + "lastModified": 1665630024, + "narHash": "sha256-xXfneoHz4h4JR58leKFoHIIapAffWlOL9HI37vwuspo=", "owner": "oxalica", "repo": "rust-overlay", - "rev": "8c727f07aa0ce5b618a3c653da75ace830485b21", + "rev": "73650741960a7422d1422f156f76211e576610c2", "type": "github" }, "original": { diff --git a/scala/flake.lock b/scala/flake.lock index d6fab38..48974ad 100644 --- a/scala/flake.lock +++ b/scala/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1665607107, - "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { diff --git a/zig/flake.lock b/zig/flake.lock index d6fab38..48974ad 100644 --- a/zig/flake.lock +++ b/zig/flake.lock @@ -17,11 +17,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1665607107, - "narHash": "sha256-ALYav/rDpqZKxP4szZw6qgCd6sol1zZKHtVwylrKxTQ=", + "lastModified": 1665685160, + "narHash": "sha256-MkNROnBdE9ocwuVrK5J/AF7zGUv6g4UhfdZ6GTrNEJA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c119e44bcce824647eff0229449374b1f0c9ad0e", + "rev": "849a740bc1342a18ce69bb08f82227202d1f7109", "type": "github" }, "original": { From 801caa1fcf9b3c424cadb4016d14f69315c2f20d Mon Sep 17 00:00:00 2001 From: Luc Perkins Date: Fri, 21 Oct 2022 11:12:21 +0200 Subject: [PATCH 4/4] Add dvt script to flake outputs --- .gitignore | 1 + flake.nix | 25 ++++++++++++++++++++++--- 2 files changed, 23 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index e9b73f9..4425c7e 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ .direnv/ target +result diff --git a/flake.nix b/flake.nix index f422940..df75779 100644 --- a/flake.nix +++ b/flake.nix @@ -133,19 +133,38 @@ ${exec "nixpkgs-fmt"} **/*.nix ''; + dvt = writeScriptBin "dvt" '' + if [ -z $1 ]; then + echo "no template specified" + exit 1 + fi + + TEMPLATE=$1 + + ${exec "nix"} \ + --experimental-features 'nix-command flakes' \ + flake init \ + --template \ + "github:the-nix-way/dev-templates#''${TEMPLATE}" + ''; + update = writeScriptBin "update" '' for dir in `ls -d */`; do # Iterate through all the templates ( cd $dir ${exec "nix"} flake update # Update flake.lock - ${ - exec "direnv" - } reload # Make sure things work after the update + ${exec "direnv"} reload # Make sure things work after the update ) done ''; in { devShells = { default = mkShell { buildInputs = [ format update ]; }; }; + + packages = rec { + default = dvt; + + inherit dvt; + }; }); }