diff --git a/flake.nix b/flake.nix index 7c827e2..5cc269c 100644 --- a/flake.nix +++ b/flake.nix @@ -8,11 +8,15 @@ outputs = { self, nixpkgs, flake-utils }: flake-utils.lib.eachDefaultSystem (system: - let pkgs = nixpkgs.legacyPackages.${system}; - in { - devShell = import ./shell.nix { - pkgs = pkgs.extend - (final: prev: { jre = prev.adoptopenjdk-hotspot-bin-11; }); + let + pkgs = import nixpkgs { + inherit system; + overlays = [ + (final: prev: rec { + jre = prev.adoptopenjdk-hotspot-bin-11; + jdk = jre; + }) + ]; }; - }); + in { devShell = import ./shell.nix { inherit pkgs; }; }); } diff --git a/flake.nix b/flake.nix index 7c827e2..5cc269c 100644 --- a/flake.nix +++ b/flake.nix @@ -8,11 +8,15 @@ outputs = { self, nixpkgs, flake-utils }: flake-utils.lib.eachDefaultSystem (system: - let pkgs = nixpkgs.legacyPackages.${system}; - in { - devShell = import ./shell.nix { - pkgs = pkgs.extend - (final: prev: { jre = prev.adoptopenjdk-hotspot-bin-11; }); + let + pkgs = import nixpkgs { + inherit system; + overlays = [ + (final: prev: rec { + jre = prev.adoptopenjdk-hotspot-bin-11; + jdk = jre; + }) + ]; }; - }); + in { devShell = import ./shell.nix { inherit pkgs; }; }); } diff --git a/shell.nix b/shell.nix index 600ee3f..bc59c53 100644 --- a/shell.nix +++ b/shell.nix @@ -1,6 +1,11 @@ -{ pkgs ? import { } }: +{ pkgs ? import { + overlays = [ + (final: prev: rec { + jre = prev.adoptopenjdk-hotspot-bin-11; + jdk = jre; + }) + ]; +} }: with pkgs; -mkShell { - buildInputs = [ jre ammonite coursier bloop sbt scalafmt ]; - } +mkShell { buildInputs = [ jre ammonite coursier bloop sbt scalafmt ]; } diff --git a/flake.nix b/flake.nix index 7c827e2..5cc269c 100644 --- a/flake.nix +++ b/flake.nix @@ -8,11 +8,15 @@ outputs = { self, nixpkgs, flake-utils }: flake-utils.lib.eachDefaultSystem (system: - let pkgs = nixpkgs.legacyPackages.${system}; - in { - devShell = import ./shell.nix { - pkgs = pkgs.extend - (final: prev: { jre = prev.adoptopenjdk-hotspot-bin-11; }); + let + pkgs = import nixpkgs { + inherit system; + overlays = [ + (final: prev: rec { + jre = prev.adoptopenjdk-hotspot-bin-11; + jdk = jre; + }) + ]; }; - }); + in { devShell = import ./shell.nix { inherit pkgs; }; }); } diff --git a/shell.nix b/shell.nix index 600ee3f..bc59c53 100644 --- a/shell.nix +++ b/shell.nix @@ -1,6 +1,11 @@ -{ pkgs ? import { } }: +{ pkgs ? import { + overlays = [ + (final: prev: rec { + jre = prev.adoptopenjdk-hotspot-bin-11; + jdk = jre; + }) + ]; +} }: with pkgs; -mkShell { - buildInputs = [ jre ammonite coursier bloop sbt scalafmt ]; - } +mkShell { buildInputs = [ jre ammonite coursier bloop sbt scalafmt ]; } diff --git a/src/main/g8/flake.nix b/src/main/g8/flake.nix index e119b6c..5cc269c 100644 --- a/src/main/g8/flake.nix +++ b/src/main/g8/flake.nix @@ -8,11 +8,15 @@ outputs = { self, nixpkgs, flake-utils }: flake-utils.lib.eachDefaultSystem (system: - let pkgs = nixpkgs.legacyPackages.\${system}; - in { - devShell = import ./shell.nix { - pkgs = pkgs.extend - (final: prev: rec { jre = prev.adoptopenjdk-hotspot-bin-$java_version$; jdk = jre; }); + let + pkgs = import nixpkgs { + inherit system; + overlays = [ + (final: prev: rec { + jre = prev.adoptopenjdk-hotspot-bin-11; + jdk = jre; + }) + ]; }; - }); + in { devShell = import ./shell.nix { inherit pkgs; }; }); } diff --git a/flake.nix b/flake.nix index 7c827e2..5cc269c 100644 --- a/flake.nix +++ b/flake.nix @@ -8,11 +8,15 @@ outputs = { self, nixpkgs, flake-utils }: flake-utils.lib.eachDefaultSystem (system: - let pkgs = nixpkgs.legacyPackages.${system}; - in { - devShell = import ./shell.nix { - pkgs = pkgs.extend - (final: prev: { jre = prev.adoptopenjdk-hotspot-bin-11; }); + let + pkgs = import nixpkgs { + inherit system; + overlays = [ + (final: prev: rec { + jre = prev.adoptopenjdk-hotspot-bin-11; + jdk = jre; + }) + ]; }; - }); + in { devShell = import ./shell.nix { inherit pkgs; }; }); } diff --git a/shell.nix b/shell.nix index 600ee3f..bc59c53 100644 --- a/shell.nix +++ b/shell.nix @@ -1,6 +1,11 @@ -{ pkgs ? import { } }: +{ pkgs ? import { + overlays = [ + (final: prev: rec { + jre = prev.adoptopenjdk-hotspot-bin-11; + jdk = jre; + }) + ]; +} }: with pkgs; -mkShell { - buildInputs = [ jre ammonite coursier bloop sbt scalafmt ]; - } +mkShell { buildInputs = [ jre ammonite coursier bloop sbt scalafmt ]; } diff --git a/src/main/g8/flake.nix b/src/main/g8/flake.nix index e119b6c..5cc269c 100644 --- a/src/main/g8/flake.nix +++ b/src/main/g8/flake.nix @@ -8,11 +8,15 @@ outputs = { self, nixpkgs, flake-utils }: flake-utils.lib.eachDefaultSystem (system: - let pkgs = nixpkgs.legacyPackages.\${system}; - in { - devShell = import ./shell.nix { - pkgs = pkgs.extend - (final: prev: rec { jre = prev.adoptopenjdk-hotspot-bin-$java_version$; jdk = jre; }); + let + pkgs = import nixpkgs { + inherit system; + overlays = [ + (final: prev: rec { + jre = prev.adoptopenjdk-hotspot-bin-11; + jdk = jre; + }) + ]; }; - }); + in { devShell = import ./shell.nix { inherit pkgs; }; }); } diff --git a/src/main/g8/shell.nix b/src/main/g8/shell.nix index 600ee3f..bc59c53 100644 --- a/src/main/g8/shell.nix +++ b/src/main/g8/shell.nix @@ -1,6 +1,11 @@ -{ pkgs ? import { } }: +{ pkgs ? import { + overlays = [ + (final: prev: rec { + jre = prev.adoptopenjdk-hotspot-bin-11; + jdk = jre; + }) + ]; +} }: with pkgs; -mkShell { - buildInputs = [ jre ammonite coursier bloop sbt scalafmt ]; - } +mkShell { buildInputs = [ jre ammonite coursier bloop sbt scalafmt ]; }