diff --git a/clojure/flake.nix b/clojure/flake.nix index dd7058e..3019144 100644 --- a/clojure/flake.nix +++ b/clojure/flake.nix @@ -3,13 +3,10 @@ inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - outputs = - { self - , nixpkgs - }: + outputs = { self, nixpkgs }: let - javaVersion = 17; + javaVersion = 20; overlays = [ (final: prev: rec { jdk = prev."jdk${toString javaVersion}"; @@ -22,7 +19,8 @@ forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { pkgs = import nixpkgs { inherit overlays system; }; }); - in { + in + { devShells = forEachSupportedSystem ({ pkgs }: { default = pkgs.mkShell { packages = with pkgs; [ boot clojure leiningen ]; diff --git a/csharp/flake.nix b/csharp/flake.nix index 1a308e0..80933d8 100644 --- a/csharp/flake.nix +++ b/csharp/flake.nix @@ -13,7 +13,8 @@ forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { pkgs = import nixpkgs { inherit system; }; }); - in { + in + { devShells = forEachSupportedSystem ({ pkgs }: { default = pkgs.mkShell { packages = with pkgs; [ diff --git a/cue/flake.lock b/cue/flake.lock index 5e1784f..0f56f8b 100644 --- a/cue/flake.lock +++ b/cue/flake.lock @@ -1,39 +1,23 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1667077288, - "narHash": "sha256-bdC8sFNDpT0HK74u9fUkpbf1MEzVYJ+ka7NXCdgBoaA=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "6ee9ebb6b1ee695d2cacc4faa053a7b9baa76817", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1677655039, - "narHash": "sha256-IsU0SSBUOr/qYTkiwIgXQ91Io/2bfXI7PG4MoJritLA=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "96a40fa5e8dee644ba60c8a966adadd2d448104a", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/cue/flake.nix b/cue/flake.nix index edfe827..75dcab0 100644 --- a/cue/flake.nix +++ b/cue/flake.nix @@ -1,28 +1,24 @@ { description = "A Nix-flake-based Cue development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; outputs = { self , nixpkgs - , flake-utils }: - flake-utils.lib.eachDefaultSystem (system: let - pkgs = import nixpkgs { inherit system; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = with pkgs; [ cue ]; - - shellHook = '' - ${pkgs.cue}/bin/cue version - ''; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ cue ]; + }; + }); + }; } diff --git a/dhall/flake.lock b/dhall/flake.lock index b6ad226..0f56f8b 100644 --- a/dhall/flake.lock +++ b/dhall/flake.lock @@ -1,39 +1,23 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1677655039, - "narHash": "sha256-IsU0SSBUOr/qYTkiwIgXQ91Io/2bfXI7PG4MoJritLA=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "96a40fa5e8dee644ba60c8a966adadd2d448104a", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/dhall/flake.nix b/dhall/flake.nix index 11ad6f3..3a78f29 100644 --- a/dhall/flake.nix +++ b/dhall/flake.nix @@ -1,44 +1,41 @@ { description = "A Nix-flake-based Dhall development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; outputs = { self , nixpkgs - , flake-utils }: - flake-utils.lib.eachDefaultSystem (system: let - pkgs = import nixpkgs { inherit system; }; - - # Helper function for building dhall-* tools - mkDhallTools = ls: - builtins.map (tool: pkgs.haskellPackages."dhall-${tool}") ls; - - dhallTools = mkDhallTools [ - "bash" - "docs" - "json" - "lsp-server" - "nix" - "nixpkgs" - "openapi" - "toml" - "yaml" - ] ++ pkgs.lib.optionals (pkgs.stdenv.isLinux) (mkDhallTools [ "csv" "text" ]); # Linux only + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = (with pkgs; [ dhall ]) ++ dhallTools; + devShells = forEachSupportedSystem ({ pkgs }: { + default = + let + # Helper function for building dhall-* tools + mkDhallTools = ls: builtins.map (tool: pkgs.haskellPackages."dhall-${tool}") ls; - shellHook = '' - echo "dhall `${pkgs.dhall}/bin/dhall --version`" - ''; - }; - }); + dhallTools = mkDhallTools [ + "bash" + "docs" + "json" + "lsp-server" + "nix" + "nixpkgs" + "openapi" + "toml" + "yaml" + ]; + in + pkgs.mkShell { + packages = (with pkgs; [ dhall ]) ++ dhallTools; + }; + }); + }; } diff --git a/elixir/flake.lock b/elixir/flake.lock index b6ad226..0f56f8b 100644 --- a/elixir/flake.lock +++ b/elixir/flake.lock @@ -1,39 +1,23 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1677655039, - "narHash": "sha256-IsU0SSBUOr/qYTkiwIgXQ91Io/2bfXI7PG4MoJritLA=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "96a40fa5e8dee644ba60c8a966adadd2d448104a", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/elixir/flake.nix b/elixir/flake.nix index f4aa3ef..110793a 100644 --- a/elixir/flake.nix +++ b/elixir/flake.nix @@ -1,32 +1,25 @@ { description = "A Nix-flake-based Elixir development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - outputs = - { self - , nixpkgs - , flake-utils - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs }: let - pkgs = import nixpkgs { inherit system; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = (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 - (with pkgs.darwin.apple_sdk.frameworks; [ CoreFoundation CoreServices ]); - - shellHook = '' - ${pkgs.elixir}/bin/mix --version - ${pkgs.elixir}/bin/iex --version - ''; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = (with pkgs; [ elixir ]) ++ + # Linux only + pkgs.lib.optionals (pkgs.stdenv.isLinux) (with pkgs; [ gigalixir inotify-tools libnotify ]) ++ + # macOS only + pkgs.lib.optionals (pkgs.stdenv.isDarwin) (with pkgs; [ terminal-notifier ]) ++ + (with pkgs.darwin.apple_sdk.frameworks; [ CoreFoundation CoreServices ]); + }; + }); + }; } diff --git a/elm/flake.lock b/elm/flake.lock index b6ad226..0f56f8b 100644 --- a/elm/flake.lock +++ b/elm/flake.lock @@ -1,39 +1,23 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1677655039, - "narHash": "sha256-IsU0SSBUOr/qYTkiwIgXQ91Io/2bfXI7PG4MoJritLA=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "96a40fa5e8dee644ba60c8a966adadd2d448104a", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/elm/flake.nix b/elm/flake.nix index 03df900..72897b7 100644 --- a/elm/flake.nix +++ b/elm/flake.nix @@ -1,28 +1,20 @@ { description = "A Nix-flake-based Elm development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - outputs = - { self - , nixpkgs - , flake-utils - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs }: let - pkgs = import nixpkgs { inherit system; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = (with pkgs.elmPackages; [ elm ]) ++ (with pkgs; [ elm2nix ]); - - shellHook = with pkgs.elmPackages; '' - echo "elm `${elm}/bin/elm --version`" - ''; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = (with pkgs.elmPackages; [ elm ]) ++ (with pkgs; [ elm2nix ]); + }; + }); + }; } diff --git a/flake.nix b/flake.nix index 0dc45a1..58a2acf 100644 --- a/flake.nix +++ b/flake.nix @@ -183,7 +183,7 @@ ( cd $dir ${exec "nix"} flake update # Update flake.lock - ${exec "direnv"} reload # Make sure things work after the update + ${exec "nix"} flake check # Make sure things work after the update ) done ''; diff --git a/gleam/flake.lock b/gleam/flake.lock index b6ad226..0f56f8b 100644 --- a/gleam/flake.lock +++ b/gleam/flake.lock @@ -1,39 +1,23 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1677655039, - "narHash": "sha256-IsU0SSBUOr/qYTkiwIgXQ91Io/2bfXI7PG4MoJritLA=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "96a40fa5e8dee644ba60c8a966adadd2d448104a", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/gleam/flake.nix b/gleam/flake.nix index 782e5c9..9b7ce64 100644 --- a/gleam/flake.nix +++ b/gleam/flake.nix @@ -1,28 +1,20 @@ { description = "A Nix-flake-based Gleam development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - outputs = - { self - , nixpkgs - , flake-utils - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs }: let - pkgs = import nixpkgs { inherit system; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = with pkgs; [ gleam ]; - - shellHook = '' - ${pkgs.gleam}/bin/gleam --version - ''; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ gleam ]; + }; + }); + }; } diff --git a/go/flake.lock b/go/flake.lock index b6ad226..0f56f8b 100644 --- a/go/flake.lock +++ b/go/flake.lock @@ -1,39 +1,23 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1677655039, - "narHash": "sha256-IsU0SSBUOr/qYTkiwIgXQ91Io/2bfXI7PG4MoJritLA=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "96a40fa5e8dee644ba60c8a966adadd2d448104a", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/go/flake.nix b/go/flake.nix index c67c1c9..0304784 100644 --- a/go/flake.nix +++ b/go/flake.nix @@ -1,39 +1,31 @@ { description = "A Nix-flake-based Go 1.17 development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - outputs = - { self - , nixpkgs - , flake-utils - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs }: let - goVersion = 19; - overlays = [ (self: super: { go = super."go_1_${toString goVersion}"; }) ]; - pkgs = import nixpkgs { inherit overlays system; }; + goVersion = 20; # Change this to update the whole stack + overlays = [ (final: prev: { go = prev."go_1_${toString goVersion}"; }) ]; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit overlays system; }; + }); in { - devShells.default = pkgs.mkShellNoCC { - packages = with pkgs; [ - # go 1.19 (specified by overlay) - go + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ + # go 1.20 (specified by overlay) + go - # goimports, godoc, etc. - gotools + # goimports, godoc, etc. + gotools - # https://github.com/golangci/golangci-lint - golangci-lint - ]; - - shellHook = '' - ${pkgs.go}/bin/go version - ''; - }; - }); + # https://github.com/golangci/golangci-lint + golangci-lint + ]; + }; + }); + }; } diff --git a/hashi/flake.lock b/hashi/flake.lock index b6ad226..80f0d19 100644 --- a/hashi/flake.lock +++ b/hashi/flake.lock @@ -1,39 +1,23 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1677655039, - "narHash": "sha256-IsU0SSBUOr/qYTkiwIgXQ91Io/2bfXI7PG4MoJritLA=", + "lastModified": 1689209875, + "narHash": "sha256-8AVcBV1DiszaZzHFd5iLc8HSLfxRAuqcU0QdfBEF3Ag=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "96a40fa5e8dee644ba60c8a966adadd2d448104a", + "rev": "fcc147b1e9358a8386b2c4368bd928e1f63a7df2", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixos-23.05", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/hashi/flake.nix b/hashi/flake.nix index ede3835..dbcc490 100644 --- a/hashi/flake.nix +++ b/hashi/flake.nix @@ -2,42 +2,32 @@ description = "A Nix-flake-based development environment for Terraform, Packer, and Nomad"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; - outputs = - { self - , nixpkgs - , flake-utils - }: + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixos-23.05"; - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs }: let - pkgs = import nixpkgs { inherit system; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = with pkgs; [ - packer - terraform - tflint - nomad - vault - nomad-autoscaler - nomad-pack - levant - damon - terragrunt - ]; - - shellHook = with pkgs; '' - echo "packer `${packer}/bin/packer --version`" - ${terraform}/bin/terraform --version - ${nomad}/bin/nomad --version - ${vault}/bin/vault --version - ''; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ + packer + terraform + tflint + nomad + vault + nomad-autoscaler + nomad-pack + levant + damon + terragrunt + ]; + }; + }); + }; } diff --git a/haskell/flake.lock b/haskell/flake.lock index b6ad226..0f56f8b 100644 --- a/haskell/flake.lock +++ b/haskell/flake.lock @@ -1,39 +1,23 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1677655039, - "narHash": "sha256-IsU0SSBUOr/qYTkiwIgXQ91Io/2bfXI7PG4MoJritLA=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "96a40fa5e8dee644ba60c8a966adadd2d448104a", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/haskell/flake.nix b/haskell/flake.nix index 9a20ed3..84fd566 100644 --- a/haskell/flake.nix +++ b/haskell/flake.nix @@ -1,29 +1,20 @@ { description = "A Nix-flake-based Haskell development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - outputs = - { self - , nixpkgs - , flake-utils - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs }: let - pkgs = import nixpkgs { inherit system; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = with pkgs; [ cabal-install ghc haskell-language-server ]; - - shellHook = with pkgs; '' - ${ghc}/bin/ghc --version - ${cabal-install}/bin/cabal --version - ''; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ cabal-install ghc haskell-language-server ]; + }; + }); + }; } diff --git a/java/flake.lock b/java/flake.lock index b6ad226..0f56f8b 100644 --- a/java/flake.lock +++ b/java/flake.lock @@ -1,39 +1,23 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1677655039, - "narHash": "sha256-IsU0SSBUOr/qYTkiwIgXQ91Io/2bfXI7PG4MoJritLA=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "96a40fa5e8dee644ba60c8a966adadd2d448104a", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/java/flake.nix b/java/flake.nix index bd7b863..5e5dd30 100644 --- a/java/flake.nix +++ b/java/flake.nix @@ -1,42 +1,28 @@ { description = "A Nix-flake-based Java development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - outputs = - { self - , nixpkgs - , flake-utils - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs }: let - javaVersion = 17; - + javaVersion = 20; # Change this value to update the whole stack overlays = [ - (self: super: rec { - jdk = super."jdk${toString javaVersion}"; - gradle = super.gradle.override { - java = jdk; - }; - maven = super.maven.override { - inherit jdk; - }; + (final: prev: rec { + jdk = prev."jdk${toString javaVersion}"; + gradle = prev.gradle.override { java = jdk; }; + maven = prev.maven.override { inherit jdk; }; }) ]; - - pkgs = import nixpkgs { inherit overlays system; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit overlays system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = with pkgs; [ gradle jdk maven ]; - - shellHook = '' - ${pkgs.jdk}/bin/java -version - ''; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ gradle jdk maven ]; + }; + }); + }; } diff --git a/kotlin/flake.lock b/kotlin/flake.lock index b6ad226..0f56f8b 100644 --- a/kotlin/flake.lock +++ b/kotlin/flake.lock @@ -1,39 +1,23 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1677655039, - "narHash": "sha256-IsU0SSBUOr/qYTkiwIgXQ91Io/2bfXI7PG4MoJritLA=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "96a40fa5e8dee644ba60c8a966adadd2d448104a", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/kotlin/flake.nix b/kotlin/flake.nix index 4e9014a..df8b79b 100644 --- a/kotlin/flake.nix +++ b/kotlin/flake.nix @@ -1,42 +1,29 @@ { description = "A Nix-flake-based Kotlin development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - outputs = - { self - , nixpkgs - , flake-utils - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs }: let - javaVersion = 17; + javaVersion = 20; overlays = [ - (self: super: rec { - jdk = pkgs."jdk${toString javaVersion}"; - gradle = super.gradle.override { - java = jdk; - }; - kotlin = super.kotlin.override { - jre = jdk; - }; + (final: prev: rec { + jdk = prev."jdk${toString javaVersion}"; + gradle = prev.gradle.override { java = jdk; }; + kotlin = prev.kotlin.override { jre = jdk; }; }) ]; - - pkgs = import nixpkgs { inherit overlays system; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = with pkgs; [ kotlin gradle gcc ncurses patchelf zlib ]; - - shellHook = '' - ${pkgs.kotlin}/bin/kotlin -version - ''; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ kotlin gradle gcc ncurses patchelf zlib ]; + }; + }); + }; } diff --git a/latex/flake.lock b/latex/flake.lock index ecac920..0f56f8b 100644 --- a/latex/flake.lock +++ b/latex/flake.lock @@ -1,39 +1,23 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1678901627, - "narHash": "sha256-U02riOqrKKzwjsxc/400XnElV+UtPUQWpANPlyazjH0=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "93a2b84fc4b70d9e089d029deacc3583435c2ed6", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1679163677, - "narHash": "sha256-VC0tc3EjJZFPXgucFQAYMIHce5nJWYR0kVCk4TVg6gg=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c3912035d00ef755ab19394488b41feab95d2e40", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/latex/flake.nix b/latex/flake.nix index 977e588..a7291ee 100644 --- a/latex/flake.nix +++ b/latex/flake.nix @@ -1,28 +1,24 @@ { description = "A Nix-flake-based LaTeX development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - outputs = - { self - , nixpkgs - , flake-utils - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs }: let - pkgs = import nixpkgs { inherit system; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = with pkgs; [ - texlive.combined.scheme-full - texlab - tectonic - ]; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ + texlive.combined.scheme-full + texlab + tectonic + ]; + }; + }); + }; } diff --git a/nickel/flake.lock b/nickel/flake.lock index b6ad226..0f56f8b 100644 --- a/nickel/flake.lock +++ b/nickel/flake.lock @@ -1,39 +1,23 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1677655039, - "narHash": "sha256-IsU0SSBUOr/qYTkiwIgXQ91Io/2bfXI7PG4MoJritLA=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "96a40fa5e8dee644ba60c8a966adadd2d448104a", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/nickel/flake.nix b/nickel/flake.nix index 5149eef..2795a2e 100644 --- a/nickel/flake.nix +++ b/nickel/flake.nix @@ -1,28 +1,20 @@ { - description = "A Nix-flake-based Protobuf development environment"; + description = "A Nix-flake-based Nickel development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - outputs = - { self - , nixpkgs - , flake-utils - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs }: let - pkgs = import nixpkgs { inherit system; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = with pkgs; [ nickel ]; - - shellHook = '' - ${pkgs.nickel}/bin/nickel --version - ''; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ nickel ]; + }; + }); + }; } diff --git a/nim/flake.lock b/nim/flake.lock index b6ad226..0f56f8b 100644 --- a/nim/flake.lock +++ b/nim/flake.lock @@ -1,39 +1,23 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1677655039, - "narHash": "sha256-IsU0SSBUOr/qYTkiwIgXQ91Io/2bfXI7PG4MoJritLA=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "96a40fa5e8dee644ba60c8a966adadd2d448104a", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/nim/flake.nix b/nim/flake.nix index 4277d5d..63368e2 100644 --- a/nim/flake.nix +++ b/nim/flake.nix @@ -1,28 +1,20 @@ { description = "A Nix-flake-based Nim development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - outputs = - { self - , nixpkgs - , flake-utils - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs }: let - pkgs = import nixpkgs { inherit system; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); in { - devShell = pkgs.mkShell { - packages = with pkgs; [ nim ]; - - shellHook = '' - ${pkgs.nim}/bin/nim --version - ''; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ nim ]; + }; + }); + }; } diff --git a/nix/flake.lock b/nix/flake.lock index b6ad226..0f56f8b 100644 --- a/nix/flake.lock +++ b/nix/flake.lock @@ -1,39 +1,23 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1677655039, - "narHash": "sha256-IsU0SSBUOr/qYTkiwIgXQ91Io/2bfXI7PG4MoJritLA=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "96a40fa5e8dee644ba60c8a966adadd2d448104a", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/nix/flake.nix b/nix/flake.nix index ec3ce8b..643d613 100644 --- a/nix/flake.nix +++ b/nix/flake.nix @@ -1,33 +1,29 @@ { description = "A Nix-flake-based Nix development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - outputs = - { self - , nixpkgs - , flake-utils - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs }: let - pkgs = import nixpkgs { inherit system; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = with pkgs; [ - cachix - lorri - niv - nixfmt - statix - vulnix - haskellPackages.dhall-nix - rnix-lsp - ]; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ + cachix + lorri + niv + nixfmt + statix + vulnix + haskellPackages.dhall-nix + rnix-lsp + ]; + }; + }); + }; } diff --git a/node/flake.lock b/node/flake.lock index b6ad226..0f56f8b 100644 --- a/node/flake.lock +++ b/node/flake.lock @@ -1,39 +1,23 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1677655039, - "narHash": "sha256-IsU0SSBUOr/qYTkiwIgXQ91Io/2bfXI7PG4MoJritLA=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "96a40fa5e8dee644ba60c8a966adadd2d448104a", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/node/flake.nix b/node/flake.nix index 34fca72..f255c1f 100644 --- a/node/flake.nix +++ b/node/flake.nix @@ -1,35 +1,27 @@ { description = "A Nix-flake-based Node.js development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - outputs = - { self - , nixpkgs - , flake-utils - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs }: let overlays = [ - (self: super: rec { - nodejs = super.nodejs-18_x; - pnpm = super.nodePackages.pnpm; - yarn = (super.yarn.override { inherit nodejs; }); + (final: prev: rec { + nodejs = prev.nodejs-18_x; + pnpm = prev.nodePackages.pnpm; + yarn = (prev.yarn.override { inherit nodejs; }); }) ]; - pkgs = import nixpkgs { inherit overlays system; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit overlays system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = with pkgs; [ node2nix nodejs pnpm yarn ]; - - shellHook = '' - echo "node `${pkgs.nodejs}/bin/node --version`" - ''; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ node2nix nodejs pnpm yarn ]; + }; + }); + }; } diff --git a/ocaml/flake.lock b/ocaml/flake.lock index b6ad226..0f56f8b 100644 --- a/ocaml/flake.lock +++ b/ocaml/flake.lock @@ -1,39 +1,23 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1677655039, - "narHash": "sha256-IsU0SSBUOr/qYTkiwIgXQ91Io/2bfXI7PG4MoJritLA=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "96a40fa5e8dee644ba60c8a966adadd2d448104a", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/ocaml/flake.nix b/ocaml/flake.nix index 1a50eb1..06e0469 100644 --- a/ocaml/flake.nix +++ b/ocaml/flake.nix @@ -1,29 +1,21 @@ { description = "A Nix-flake-based OCaml development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - outputs = - { self - , nixpkgs - , flake-utils - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs }: let - pkgs = import nixpkgs { inherit system; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = with pkgs; [ ocaml ocamlformat ] ++ - (with pkgs.ocamlPackages; [ dune_3 odoc ]); - - shellHook = '' - ${pkgs.ocaml}/bin/ocaml --version - ''; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ ocaml ocamlformat ] ++ + (with pkgs.ocamlPackages; [ dune_3 odoc ]); + }; + }); + }; } diff --git a/opa/flake.lock b/opa/flake.lock index b6ad226..0f56f8b 100644 --- a/opa/flake.lock +++ b/opa/flake.lock @@ -1,39 +1,23 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1677655039, - "narHash": "sha256-IsU0SSBUOr/qYTkiwIgXQ91Io/2bfXI7PG4MoJritLA=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "96a40fa5e8dee644ba60c8a966adadd2d448104a", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/opa/flake.nix b/opa/flake.nix index c1a0503..6263edf 100644 --- a/opa/flake.nix +++ b/opa/flake.nix @@ -1,28 +1,20 @@ { description = "A Nix-flake-based Open Policy Agent development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - outputs = - { self - , nixpkgs - , flake-utils - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs }: let - pkgs = import nixpkgs { inherit system; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = with pkgs; [ open-policy-agent conftest ]; - - shellHook = '' - ${pkgs.open-policy-agent}/bin/opa version - ''; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ open-policy-agent conftest ]; + }; + }); + }; } diff --git a/php/flake.lock b/php/flake.lock index b6ad226..0f56f8b 100644 --- a/php/flake.lock +++ b/php/flake.lock @@ -1,39 +1,23 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1677655039, - "narHash": "sha256-IsU0SSBUOr/qYTkiwIgXQ91Io/2bfXI7PG4MoJritLA=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "96a40fa5e8dee644ba60c8a966adadd2d448104a", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/php/flake.nix b/php/flake.nix index 59d063d..500c21b 100644 --- a/php/flake.nix +++ b/php/flake.nix @@ -1,28 +1,20 @@ { description = "A Nix-flake-based PHP development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - outputs = - { self - , nixpkgs - , flake-utils - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs }: let - pkgs = import nixpkgs { inherit system; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); in { - devShell = pkgs.mkShell { - packages = with pkgs; [ phpPackages.composer php ]; - - shellHook = '' - echo "`${pkgs.php}/bin/php --version`" - ''; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ php phpPackages.composer ]; + }; + }); + }; } diff --git a/protobuf/flake.lock b/protobuf/flake.lock index b6ad226..0f56f8b 100644 --- a/protobuf/flake.lock +++ b/protobuf/flake.lock @@ -1,39 +1,23 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1677655039, - "narHash": "sha256-IsU0SSBUOr/qYTkiwIgXQ91Io/2bfXI7PG4MoJritLA=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "96a40fa5e8dee644ba60c8a966adadd2d448104a", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/protobuf/flake.nix b/protobuf/flake.nix index 1da1ba8..04206fd 100644 --- a/protobuf/flake.nix +++ b/protobuf/flake.nix @@ -1,29 +1,20 @@ { description = "A Nix-flake-based Protobuf development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - outputs = - { self - , nixpkgs - , flake-utils - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs }: let - pkgs = import nixpkgs { inherit system; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = with pkgs; [ buf protobuf ]; - - shellHook = with pkgs; '' - echo "buf `${buf}/bin/buf --version`" - ${protobuf}/bin/protoc --version - ''; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ protobuf buf ]; + }; + }); + }; } diff --git a/purescript/flake.lock b/purescript/flake.lock index 6f42f5e..4e78d08 100644 --- a/purescript/flake.lock +++ b/purescript/flake.lock @@ -3,11 +3,11 @@ "easy-purescript-nix": { "flake": false, "locked": { - "lastModified": 1671011575, - "narHash": "sha256-tESal32bcqqdZO+aKnBzc1GoL2mtnaDtj2y7ociCRGA=", + "lastModified": 1686900973, + "narHash": "sha256-9whTjp8BYy8ZzyghhgbawS06/dVESduME3wsdNH/mpk=", "owner": "justinwoo", "repo": "easy-purescript-nix", - "rev": "11d3bd58ce6e32703bf69cec04dc7c38eabe14ba", + "rev": "8cf400656945b2f2bacfd6a8775792aa701f60e9", "type": "github" }, "original": { @@ -16,33 +16,18 @@ "type": "github" } }, - "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1677655039, - "narHash": "sha256-IsU0SSBUOr/qYTkiwIgXQ91Io/2bfXI7PG4MoJritLA=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "96a40fa5e8dee644ba60c8a966adadd2d448104a", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } @@ -50,7 +35,6 @@ "root": { "inputs": { "easy-purescript-nix": "easy-purescript-nix", - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/purescript/flake.nix b/purescript/flake.nix index 63d6f54..c92ccc4 100644 --- a/purescript/flake.nix +++ b/purescript/flake.nix @@ -2,42 +2,34 @@ description = "A Nix-flake-based Purescript development environment"; inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; + nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; easy-purescript-nix = { url = "github:justinwoo/easy-purescript-nix"; flake = false; }; }; - outputs = - { self - , nixpkgs - , flake-utils - , easy-purescript-nix - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs, easy-purescript-nix }: let - pkgs = import nixpkgs { inherit system; }; - easy-ps = import easy-purescript-nix { inherit pkgs; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = (with pkgs; [ nodejs ]) ++ (with easy-ps; [ - purs - spago - purescript-language-server - purs-tidy - ]); - - shellHook = with easy-ps; '' - echo "Purs `${purs}/bin/purs --version`" - echo "Spago `${spago}/bin/spago --version`" - echo "Purescript Language Server `${purescript-language-server}/bin/purescript-language-server --version`" - echo "Purs Tidy `${purs-tidy}/bin/purs-tidy --version`" - echo "Node.js `${pkgs.nodejs}/bin/node --version`" - ''; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = + let + easy-ps = import easy-purescript-nix { inherit pkgs; }; + in + pkgs.mkShell { + packages = (with pkgs; [ nodejs ]) ++ (with easy-ps; [ + purs + spago + purescript-language-server + purs-tidy + ]); + }; + }); + }; } diff --git a/python/flake.lock b/python/flake.lock index 22fe482..0f56f8b 100644 --- a/python/flake.lock +++ b/python/flake.lock @@ -1,107 +1,24 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, - "flake-utils_2": { - "locked": { - "lastModified": 1642700792, - "narHash": "sha256-XqHrk7hFb+zBvRg6Ghl+AZDq03ov6OshJLiSWOoX5es=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "846b2ae0fc4cc943637d3d1def4454213e203cba", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, - "mach-nix": { - "inputs": { - "flake-utils": "flake-utils_2", - "nixpkgs": "nixpkgs", - "pypi-deps-db": "pypi-deps-db" - }, - "locked": { - "lastModified": 1674628768, - "narHash": "sha256-mia90VYv/YTdWNhKpvwvFW9RfbXZJSWhJ+yva6EnLE8=", - "owner": "DavHau", - "repo": "mach-nix", - "rev": "70daee1b200c9a24a0f742f605edadacdcb5c998", - "type": "github" - }, - "original": { - "owner": "DavHau", - "repo": "mach-nix", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1643805626, - "narHash": "sha256-AXLDVMG+UaAGsGSpOtQHPIKB+IZ0KSd9WS77aanGzgc=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "554d2d8aa25b6e583575459c297ec23750adb6cb", - "type": "github" - }, - "original": { - "id": "nixpkgs", - "ref": "nixos-unstable", - "type": "indirect" - } - }, - "nixpkgs_2": { - "locked": { - "lastModified": 1677655039, - "narHash": "sha256-IsU0SSBUOr/qYTkiwIgXQ91Io/2bfXI7PG4MoJritLA=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "96a40fa5e8dee644ba60c8a966adadd2d448104a", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, - "pypi-deps-db": { - "flake": false, - "locked": { - "lastModified": 1661155889, - "narHash": "sha256-t00mBTZhmZBT4jteO6pJbU0wyRS6/ep4pKmQNeztEms=", - "owner": "DavHau", - "repo": "pypi-deps-db", - "rev": "49c620f3de2b557c9d5c44f58a00fee59f27d1b0", - "type": "github" - }, - "original": { - "owner": "DavHau", - "repo": "pypi-deps-db", - "type": "github" - } - }, "root": { "inputs": { - "flake-utils": "flake-utils", - "mach-nix": "mach-nix", - "nixpkgs": "nixpkgs_2" + "nixpkgs": "nixpkgs" } } }, diff --git a/python/flake.nix b/python/flake.nix index 977e816..8871da2 100644 --- a/python/flake.nix +++ b/python/flake.nix @@ -1,38 +1,22 @@ { description = "A Nix-flake-based Python development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - mach-nix.url = "github:/DavHau/mach-nix"; - }; - outputs = - { self - , nixpkgs - , flake-utils - , mach-nix - }: + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs }: let - overlays = [ - (self: super: { - machNix = mach-nix.defaultPackage.${system}; - python = super.python311; - }) - ]; - - pkgs = import nixpkgs { inherit overlays system; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = with pkgs; [ python machNix virtualenv ] ++ - (with pkgs.python311Packages; [ pip ]); - - shellHook = '' - ${pkgs.python}/bin/python --version - ''; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ python311 virtualenv ] ++ + (with pkgs.python311Packages; [ pip ]); + }; + }); + }; } diff --git a/ruby/flake.lock b/ruby/flake.lock index 5e1784f..0f56f8b 100644 --- a/ruby/flake.lock +++ b/ruby/flake.lock @@ -1,39 +1,23 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1667077288, - "narHash": "sha256-bdC8sFNDpT0HK74u9fUkpbf1MEzVYJ+ka7NXCdgBoaA=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "6ee9ebb6b1ee695d2cacc4faa053a7b9baa76817", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1677655039, - "narHash": "sha256-IsU0SSBUOr/qYTkiwIgXQ91Io/2bfXI7PG4MoJritLA=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "96a40fa5e8dee644ba60c8a966adadd2d448104a", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/ruby/flake.nix b/ruby/flake.nix index abc3be8..5cc2d48 100644 --- a/ruby/flake.nix +++ b/ruby/flake.nix @@ -1,33 +1,20 @@ { description = "A Nix-flake-based Ruby development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - outputs = - { self - , nixpkgs - , flake-utils - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs }: let - overlays = [ - (self: super: { - ruby = super.ruby_3_1; - }) - ]; - pkgs = import nixpkgs { inherit overlays system; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = with pkgs; [ ruby ]; - - shellHook = '' - ${pkgs.ruby}/bin/ruby --version - ''; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ ruby_3_2 ]; + }; + }); + }; } diff --git a/rust-toolchain/flake.lock b/rust-toolchain/flake.lock index d0ee63f..e62923d 100644 --- a/rust-toolchain/flake.lock +++ b/rust-toolchain/flake.lock @@ -1,27 +1,15 @@ { "nodes": { "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" + "inputs": { + "systems": "systems" }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, - "flake-utils_2": { "locked": { - "lastModified": 1659877975, - "narHash": "sha256-zllb8aq3YO3h8B/U0/J1WBgAL8EX5yWf5pMj3G0NAmc=", + "lastModified": 1681202837, + "narHash": "sha256-H+Rh19JDwRtpVPAWp64F+rlEtxUWBAQW28eAi3SRSzg=", "owner": "numtide", "repo": "flake-utils", - "rev": "c0e246b9b83f637f4681389ecabcb2681b4f3af0", + "rev": "cfacdce06f30d2b68473a46042957675eebb3401", "type": "github" }, "original": { @@ -32,27 +20,27 @@ }, "nixpkgs": { "locked": { - "lastModified": 1678101631, - "narHash": "sha256-vuuvWBNGhNSPPbFCjp2XZmBqJOvsFF1T0hyleRnHZlc=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "934e613c31cf7af0624dcf088b9e2d9b802d0717", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "nixpkgs_2": { "locked": { - "lastModified": 1665296151, - "narHash": "sha256-uOB0oxqxN9K7XGF1hcnY+PQnlQJ+3bP2vCn/+Ru/bbc=", + "lastModified": 1681358109, + "narHash": "sha256-eKyxW4OohHQx9Urxi7TQlFBTDWII+F+x2hklDOQPB50=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "14ccaaedd95a488dd7ae142757884d8e125b3363", + "rev": "96ba1c52e54e74c3197f4d43026b3f3d92e83ff9", "type": "github" }, "original": { @@ -64,22 +52,21 @@ }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs", "rust-overlay": "rust-overlay" } }, "rust-overlay": { "inputs": { - "flake-utils": "flake-utils_2", + "flake-utils": "flake-utils", "nixpkgs": "nixpkgs_2" }, "locked": { - "lastModified": 1676341851, - "narHash": "sha256-T8cmSiriXdpZfqlserNyJ1solTCR0DbD8A75epSDOVY=", + "lastModified": 1689215707, + "narHash": "sha256-Wuqkwdjtox/CfCq71p1pVBRd0VTR1Hw3+cb/zdvxOHI=", "owner": "oxalica", "repo": "rust-overlay", - "rev": "956ddb5047f98ea08b792b22004b94a9971932c4", + "rev": "7a1c8fd0f90694af49b89181344096e3375f2e23", "type": "github" }, "original": { @@ -87,6 +74,21 @@ "repo": "rust-overlay", "type": "github" } + }, + "systems": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } } }, "root": "root", diff --git a/rust-toolchain/flake.nix b/rust-toolchain/flake.nix index a876c0e..0aef75e 100644 --- a/rust-toolchain/flake.nix +++ b/rust-toolchain/flake.nix @@ -2,32 +2,27 @@ description = "A Nix-flake-based Rust development environment"; inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; + nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; rust-overlay.url = "github:oxalica/rust-overlay"; }; - outputs = - { self - , nixpkgs - , flake-utils - , rust-overlay - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs, rust-overlay }: let overlays = [ - (import rust-overlay) - (self: super: { - rustToolchain = super.rust-bin.fromRustupToolchainFile ./rust-toolchain.toml; + rust-overlay.overlays.default + (final: prev: { + rustToolchain = prev.rust-bin.fromRustupToolchainFile ./rust-toolchain.toml; }) ]; - - pkgs = import nixpkgs { inherit system overlays; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit overlays system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = with pkgs; [ + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ rustToolchain openssl pkg-config @@ -36,10 +31,7 @@ cargo-watch rust-analyzer ]; - - shellHook = '' - ${pkgs.rustToolchain}/bin/cargo --version - ''; - }; - }); + }; + }); + }; } diff --git a/rust-toolchain/rust-toolchain.toml b/rust-toolchain/rust-toolchain.toml index 588ffd5..f2415f8 100644 --- a/rust-toolchain/rust-toolchain.toml +++ b/rust-toolchain/rust-toolchain.toml @@ -1,2 +1,2 @@ [toolchain] -channel = "1.67.1" +channel = "1.69.0" diff --git a/rust/flake.lock b/rust/flake.lock index 2578f0c..e62923d 100644 --- a/rust/flake.lock +++ b/rust/flake.lock @@ -1,27 +1,15 @@ { "nodes": { "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" + "inputs": { + "systems": "systems" }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, - "flake-utils_2": { "locked": { - "lastModified": 1659877975, - "narHash": "sha256-zllb8aq3YO3h8B/U0/J1WBgAL8EX5yWf5pMj3G0NAmc=", + "lastModified": 1681202837, + "narHash": "sha256-H+Rh19JDwRtpVPAWp64F+rlEtxUWBAQW28eAi3SRSzg=", "owner": "numtide", "repo": "flake-utils", - "rev": "c0e246b9b83f637f4681389ecabcb2681b4f3af0", + "rev": "cfacdce06f30d2b68473a46042957675eebb3401", "type": "github" }, "original": { @@ -32,27 +20,27 @@ }, "nixpkgs": { "locked": { - "lastModified": 1677655039, - "narHash": "sha256-IsU0SSBUOr/qYTkiwIgXQ91Io/2bfXI7PG4MoJritLA=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "96a40fa5e8dee644ba60c8a966adadd2d448104a", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "nixpkgs_2": { "locked": { - "lastModified": 1665296151, - "narHash": "sha256-uOB0oxqxN9K7XGF1hcnY+PQnlQJ+3bP2vCn/+Ru/bbc=", + "lastModified": 1681358109, + "narHash": "sha256-eKyxW4OohHQx9Urxi7TQlFBTDWII+F+x2hklDOQPB50=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "14ccaaedd95a488dd7ae142757884d8e125b3363", + "rev": "96ba1c52e54e74c3197f4d43026b3f3d92e83ff9", "type": "github" }, "original": { @@ -64,22 +52,21 @@ }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs", "rust-overlay": "rust-overlay" } }, "rust-overlay": { "inputs": { - "flake-utils": "flake-utils_2", + "flake-utils": "flake-utils", "nixpkgs": "nixpkgs_2" }, "locked": { - "lastModified": 1676341851, - "narHash": "sha256-T8cmSiriXdpZfqlserNyJ1solTCR0DbD8A75epSDOVY=", + "lastModified": 1689215707, + "narHash": "sha256-Wuqkwdjtox/CfCq71p1pVBRd0VTR1Hw3+cb/zdvxOHI=", "owner": "oxalica", "repo": "rust-overlay", - "rev": "956ddb5047f98ea08b792b22004b94a9971932c4", + "rev": "7a1c8fd0f90694af49b89181344096e3375f2e23", "type": "github" }, "original": { @@ -87,6 +74,21 @@ "repo": "rust-overlay", "type": "github" } + }, + "systems": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } } }, "root": "root", diff --git a/rust/flake.nix b/rust/flake.nix index bbc2371..dee45ec 100644 --- a/rust/flake.nix +++ b/rust/flake.nix @@ -2,26 +2,18 @@ description = "A Nix-flake-based Rust development environment"; inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; + nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; rust-overlay.url = "github:oxalica/rust-overlay"; }; - outputs = - { self - , nixpkgs - , flake-utils - , rust-overlay - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs, rust-overlay }: let overlays = [ - (import rust-overlay) - (self: super: { + rust-overlay.overlays.default + (final: prev: { rustToolchain = let - rust = super.rust-bin; + rust = prev.rust-bin; in if builtins.pathExists ./rust-toolchain.toml then rust.fromRustupToolchainFile ./rust-toolchain.toml @@ -31,12 +23,15 @@ rust.stable.latest.default; }) ]; - - pkgs = import nixpkgs { inherit system overlays; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit overlays system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = with pkgs; [ + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ rustToolchain openssl pkg-config @@ -45,10 +40,7 @@ cargo-watch rust-analyzer ]; - - shellHook = '' - ${pkgs.rustToolchain}/bin/cargo --version - ''; - }; - }); + }; + }); + }; } diff --git a/scala/flake.lock b/scala/flake.lock index f26e416..0f56f8b 100644 --- a/scala/flake.lock +++ b/scala/flake.lock @@ -1,39 +1,23 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1678101631, - "narHash": "sha256-vuuvWBNGhNSPPbFCjp2XZmBqJOvsFF1T0hyleRnHZlc=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "934e613c31cf7af0624dcf088b9e2d9b802d0717", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/scala/flake.nix b/scala/flake.nix index 5bc4b0f..419bea7 100644 --- a/scala/flake.nix +++ b/scala/flake.nix @@ -1,42 +1,28 @@ { description = "A Nix-flake-based Scala development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - outputs = - { self - , nixpkgs - , flake-utils - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs }: let - javaVersion = 17; - + javaVersion = 20; overlays = [ - (self: super: rec { - jdk = super."jdk${toString javaVersion}"; - sbt = super.sbt.override { - jre = jdk; - }; - scala = super.scala_3.override { - jre = jdk; - }; + (final: prev: rec { + jdk = prev."jdk${toString javaVersion}"; + sbt = prev.sbt.override { jre = jdk; }; + scala = prev.scala_3.override { jre = jdk; }; }) ]; - - pkgs = import nixpkgs { inherit overlays system; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = with pkgs; [ scala sbt coursier ]; - - shellHook = '' - ${pkgs.scala}/bin/scala -version - ''; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ scala sbt coursier ]; + }; + }); + }; } diff --git a/shell/flake.lock b/shell/flake.lock index 10767eb..0f56f8b 100644 --- a/shell/flake.lock +++ b/shell/flake.lock @@ -1,59 +1,25 @@ { "nodes": { - "flake-utils": { - "inputs": { - "systems": "systems" - }, - "locked": { - "lastModified": 1681202837, - "narHash": "sha256-H+Rh19JDwRtpVPAWp64F+rlEtxUWBAQW28eAi3SRSzg=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "cfacdce06f30d2b68473a46042957675eebb3401", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1685014919, - "narHash": "sha256-2hsL8OrGYmu68UHWVZbyN/ZyuJuESbvJF6ZqHVHUdXE=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "ea60cf854a9216d3276134ff2df67952766b4198", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } - }, - "systems": { - "locked": { - "lastModified": 1681028828, - "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", - "owner": "nix-systems", - "repo": "default", - "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", - "type": "github" - }, - "original": { - "owner": "nix-systems", - "repo": "default", - "type": "github" - } } }, "root": "root", diff --git a/shell/flake.nix b/shell/flake.nix index 465d7df..d108443 100644 --- a/shell/flake.nix +++ b/shell/flake.nix @@ -1,26 +1,20 @@ { description = "A Nix-flake-based Shell development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - outputs = - { self - , nixpkgs - , flake-utils - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs }: let - pkgs = import nixpkgs { inherit system; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = with pkgs; [ - shellcheck - ]; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ shellcheck ]; + }; + }); + }; } diff --git a/zig/flake.lock b/zig/flake.lock index f26e416..0f56f8b 100644 --- a/zig/flake.lock +++ b/zig/flake.lock @@ -1,39 +1,23 @@ { "nodes": { - "flake-utils": { - "locked": { - "lastModified": 1676283394, - "narHash": "sha256-XX2f9c3iySLCw54rJ/CZs+ZK6IQy7GXNY4nSOyu2QG4=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "3db36a8b464d0c4532ba1c7dda728f4576d6d073", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1678101631, - "narHash": "sha256-vuuvWBNGhNSPPbFCjp2XZmBqJOvsFF1T0hyleRnHZlc=", + "lastModified": 1689261696, + "narHash": "sha256-LzfUtFs9MQRvIoQ3MfgSuipBVMXslMPH/vZ+nM40LkA=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "934e613c31cf7af0624dcf088b9e2d9b802d0717", + "rev": "df1eee2aa65052a18121ed4971081576b25d6b5c", "type": "github" }, "original": { "owner": "NixOS", - "ref": "release-22.11", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "root": { "inputs": { - "flake-utils": "flake-utils", "nixpkgs": "nixpkgs" } } diff --git a/zig/flake.nix b/zig/flake.nix index f4b3e0b..7a02b70 100644 --- a/zig/flake.nix +++ b/zig/flake.nix @@ -1,28 +1,20 @@ { description = "A Nix-flake-based Zig development environment"; - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/release-22.11"; - flake-utils.url = "github:numtide/flake-utils"; - }; + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; - outputs = - { self - , nixpkgs - , flake-utils - }: - - flake-utils.lib.eachDefaultSystem (system: + outputs = { self, nixpkgs }: let - pkgs = import nixpkgs { inherit system; }; + supportedSystems = [ "x86_64-linux" "aarch64-linux" "x86_64-darwin" "aarch64-darwin" ]; + forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f { + pkgs = import nixpkgs { inherit system; }; + }); in { - devShells.default = pkgs.mkShell { - packages = with pkgs; [ zig ]; - - shellHook = '' - echo "zig `${pkgs.zig}/bin/zig version`" - ''; - }; - }); + devShells = forEachSupportedSystem ({ pkgs }: { + default = pkgs.mkShell { + packages = with pkgs; [ zig ]; + }; + }); + }; }