Skip to content

Commit

Permalink
refactor(templates): remove rec
Browse files Browse the repository at this point in the history
  • Loading branch information
isabelroses committed Nov 27, 2024
1 parent 8b04497 commit 3c812ba
Show file tree
Hide file tree
Showing 7 changed files with 19 additions and 19 deletions.
6 changes: 3 additions & 3 deletions parts/templates/c/flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
};

outputs =
{ nixpkgs, ... }:
{ self, nixpkgs }:
let
forAllSystems =
function:
Expand All @@ -15,9 +15,9 @@
);
in
{
packages = forAllSystems (pkgs: rec {
packages = forAllSystems (pkgs: {
example = pkgs.callPackage ./default.nix { };
default = example;
default = self.packages.${pkgs.stdenv.hostPlatform.system}.example;
});

devShells = forAllSystems (pkgs: {
Expand Down
6 changes: 3 additions & 3 deletions parts/templates/go/flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
};

outputs =
{ nixpkgs, ... }:
{ self, nixpkgs }:
let
forAllSystems =
function:
Expand All @@ -15,9 +15,9 @@
);
in
{
packages = forAllSystems (pkgs: rec {
packages = forAllSystems (pkgs: {
example = pkgs.callPackage ./default.nix { };
default = example;
default = self.packages.${pkgs.stdenv.hostPlatform.system}.example;
});

devShells = forAllSystems (pkgs: {
Expand Down
2 changes: 1 addition & 1 deletion parts/templates/haskell/flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
{
packages = forAllSystems (pkgs: {
example = pkgs.callPackage ./default.nix { };
default = self.packages.example;
default = self.packages.${pkgs.stdenv.hostPlatform.system}.example;
});

devShells = forAllSystems (pkgs: {
Expand Down
6 changes: 3 additions & 3 deletions parts/templates/latex/flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
};

outputs =
{ nixpkgs, ... }:
{ self, nixpkgs }:
let
forAllSystems =
function:
Expand All @@ -15,9 +15,9 @@
);
in
{
packages = forAllSystems (pkgs: rec {
packages = forAllSystems (pkgs: {
example = pkgs.callPackage ./default.nix { };
default = example;
default = self.packages.${pkgs.stdenv.hostPlatform.system}.example;
});

devShells = forAllSystems (pkgs: {
Expand Down
6 changes: 3 additions & 3 deletions parts/templates/node/flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
};

outputs =
{ nixpkgs, ... }:
{ self, nixpkgs }:
let
forAllSystems =
function:
Expand All @@ -15,9 +15,9 @@
);
in
{
packages = forAllSystems (pkgs: rec {
packages = forAllSystems (pkgs: {
example = pkgs.callPackage ./default.nix { };
default = example;
default = self.packages.${pkgs.stdenv.hostPlatform.system}.example;
});

devShells = forAllSystems (pkgs: {
Expand Down
6 changes: 3 additions & 3 deletions parts/templates/python/flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
};

outputs =
{ nixpkgs, ... }:
{ self, nixpkgs }:
let
forAllSystems =
function:
Expand All @@ -15,9 +15,9 @@
);
in
{
packages = forAllSystems (pkgs: rec {
packages = forAllSystems (pkgs: {
example = pkgs.callPackage ./default.nix { };
default = example;
default = self.packages.${pkgs.stdenv.hostPlatform.system}.example;
});

devShells = forAllSystems (pkgs: {
Expand Down
6 changes: 3 additions & 3 deletions parts/templates/rust/flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
};

outputs =
{ nixpkgs, ... }:
{ self, nixpkgs }:
let
forAllSystems =
function:
Expand All @@ -15,9 +15,9 @@
);
in
{
packages = forAllSystems (pkgs: rec {
packages = forAllSystems (pkgs: {
example = pkgs.callPackage ./default.nix { };
default = example;
default = self.packages.${pkgs.stdenv.hostPlatform.system}.example;
});

devShells = forAllSystems (pkgs: {
Expand Down

0 comments on commit 3c812ba

Please sign in to comment.