Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 0 additions & 20 deletions overview/content-types/config-item.nix

This file was deleted.

29 changes: 0 additions & 29 deletions overview/content-types/nix-config.nix

This file was deleted.

45 changes: 20 additions & 25 deletions overview/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -300,31 +300,26 @@ let
}
];
};
nix-config = eval {
imports = [ ./content-types/nix-config.nix ];
settings = [
{
name = "substituters";
value = [
"https://cache.nixos.org/"
"https://ngi.cachix.org/"
];
}
{
name = "trusted-public-keys";
value = [
"cache.nixos.org-1:6nchdd59x431o0gwypbmraurkbj16zpmqfgspcdshjy="
"ngi.cachix.org-1:n+cal72roc3qqulxihpv+tw5t42whxmmhpragkrsrow="
];
}
];
};
set-nix-config = eval {
imports = [ ./content-types/commands.nix ];
instructions.commands.bash.input = ''
export ${nix-config}
'';
};
set-nix-config =
let
from-yaml =
file:
with builtins;
fromJSON (
# XXX(@fricklerhandwerk): IFD, sorry. I was there, Gandalf: https://github.com/NixOS/nix/pull/7340
readFile (pkgs.runCommandNoCC "yaml.json" { } "${lib.getExe pkgs.yj} < ${file} > $out")
);
workflow = from-yaml ../.github/workflows/test-demo.yaml;
nix-config = with lib; trim (elemAt workflow.jobs.test.steps 3).env.NIX_CONFIG;
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We may want to have some assertion here that the string starts with extra- or something, such that changing the order of entries won't have surprising effects on the overview.

in
eval {
imports = [ ./content-types/commands.nix ];
instructions.commands.bash.input = ''
export NIX_CONFIG="
${nix-config}
"
'';
};
in
''
${heading 2 "demo" (
Expand Down