From 35b09eb73a85cf8bcf95249fea0ff5e9065a0ae8 Mon Sep 17 00:00:00 2001 From: Jonni Liljamo Date: Sat, 26 Oct 2024 21:27:44 +0300 Subject: [PATCH] feat: add second nix package for src.quest robots.txt --- flake.nix | 30 +++++++++++++++++++++++------- 1 file changed, 23 insertions(+), 7 deletions(-) diff --git a/flake.nix b/flake.nix index 89bf106..40cefff 100644 --- a/flake.nix +++ b/flake.nix @@ -4,13 +4,29 @@ }; outputs = { self, nixpkgs }: { - packages.x86_64-linux.default = nixpkgs.legacyPackages.x86_64-linux.pkgs.stdenv.mkDerivation { - name = "robots.txt"; - src = ./.; - installPhase = '' - mkdir -p $out - cp robots.txt $out - ''; + packages.x86_64-linux = { + default = nixpkgs.legacyPackages.x86_64-linux.pkgs.stdenv.mkDerivation { + name = "robots.txt"; + src = ./.; + buildPhase = '' + bash generate.sh robots.txt + ''; + installPhase = '' + mkdir -p $out + cp robots.txt $out + ''; + }; + "src-quest" = nixpkgs.legacyPackages.x86_64-linux.pkgs.stdenv.mkDerivation { + name = "robots.txt-src.quest"; + src = ./.; + buildPhase = '' + bash generate.sh robots.txt ./bases/src.quest + ''; + installPhase = '' + mkdir -p $out + cp robots.txt $out + ''; + }; }; }; } -- 2.44.1