feat: lots of things, really

This commit is contained in:
Kat Inskip 2024-11-13 19:30:43 -05:00
parent 5448280ec8
commit 185833d1fb
Signed by: kat
GPG key ID: 465E64DECEA8CF0F
28 changed files with 200 additions and 168 deletions

View file

@ -1,12 +1,9 @@
{
inputs,
...
}@args:
inputs.utils.lib.eachDefaultSystem (system: let
newArgs = args // { inherit system; };
in {
packages = {
nf-actions-test = import ./nf-actions-test.nix newArgs;
nf-generate = import ./nf-generate.nix newArgs;
};
})
{inputs, ...} @ args:
inputs.utils.lib.eachDefaultSystem (system: let
newArgs = args // {inherit system;};
in {
packages = {
nf-actions-test = import ./nf-actions-test.nix newArgs;
nf-generate = import ./nf-generate.nix newArgs;
};
})

View file

@ -1,9 +1,5 @@
{
system,
inputs,
...
}: let
inherit (inputs.std.lib) string list set;
{inputs, ...}: let
inherit (inputs.std.lib) string set;
inherit (inputs.self) systems;
enabledNixosSystems = set.filter (_: system: system.config.ci.enable && system.config.type == "NixOS") systems;
in {

View file

@ -2,16 +2,14 @@
system,
inputs,
...
}@args: let
lib = inputs.nixpkgs.lib;
} @ args: let
exportFile = import ./exports.nix args;
inherit (exportFile) exports exportsSystems;
inherit (inputs.std.lib) string list set;
packages = inputs.self.packages.${system};
inherit (inputs.self.legacyPackages.${system}) pkgs;
nf-actions-test = pkgs.writeShellScriptBin "nf-actions-test" ''
${exports}
${exportsSystems}
source ${./actions-test.sh}
${exports}
${exportsSystems}
source ${./actions-test.sh}
'';
in nf-actions-test
in
nf-actions-test

View file

@ -2,20 +2,20 @@
system,
inputs,
...
}@args: let
lib = inputs.nixpkgs.lib;
} @ args: let
inherit (inputs.nixpkgs) lib;
exportFile = import ./exports.nix args;
inherit (exportFile) exports exportsSystems;
inherit (exportFile) exports;
inherit (lib.strings) makeBinPath;
inherit (inputs.std.lib) string list set;
packages = inputs.self.packages.${system};
inherit (inputs.std.lib) string;
inherit (inputs.self.legacyPackages.${system}) pkgs;
inherit (import ../ci/nix.nix) ci;
nf-generate = pkgs.writeShellScriptBin "nf-generate" ''
${exports}
export PATH="$PATH:${makeBinPath [pkgs.jq]}"
NF_INPUT_CI=${string.escapeShellArg inputs.ci}
NF_CONFIG_FILES=(${string.concatMapSep " " string.escapeShellArg ci.workflowConfigs})
source ${./generate.sh}
'';
in nf-generate
nf-generate = pkgs.writeShellScriptBin "nf-generate" ''
${exports}
export PATH="$PATH:${makeBinPath [pkgs.jq]}"
NF_INPUT_CI=${string.escapeShellArg inputs.ci}
NF_CONFIG_FILES=(${string.concatMapSep " " string.escapeShellArg ci.workflowConfigs})
source ${./generate.sh}
'';
in
nf-generate