Add basic directed acyclic graph data structure
Also make use of this instead of Nixpkgs's strings-with-deps library in activation script generation.
This commit is contained in:
parent
62a9a8fa3c
commit
8fab2a5d9b
4 changed files with 153 additions and 22 deletions
|
|
@ -1,6 +1,7 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
with lib;
|
||||
with import ../lib/dag.nix;
|
||||
|
||||
let
|
||||
|
||||
|
|
@ -177,18 +178,19 @@ in
|
|||
config = mkIf cfg.enable {
|
||||
home.packages = [ pkgs.gnome3.gnome_terminal ];
|
||||
|
||||
home.activation.gnomeTerminal =
|
||||
# The dconf service needs to be installed and prepared.
|
||||
home.activation.gnomeTerminal = dagEntryAfter ["installPackages"] (
|
||||
let
|
||||
sf = pkgs.writeText "gnome-terminal.ini" (toINI (buildIniSet cfg));
|
||||
dconfPath = "/org/gnome/terminal/legacy/";
|
||||
in
|
||||
# The dconf service needs to be installed and prepared.
|
||||
stringAfter [ "installPackages" ] ''
|
||||
''
|
||||
if [[ -v DRY_RUN ]]; then
|
||||
echo ${pkgs.gnome3.dconf}/bin/dconf load ${dconfPath} "<" ${sf}
|
||||
else
|
||||
${pkgs.gnome3.dconf}/bin/dconf load ${dconfPath} < ${sf}
|
||||
fi
|
||||
'';
|
||||
''
|
||||
);
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue