diff options
author | Robert Helgesson <robert@rycee.net> | 2017-12-02 19:15:13 +0100 |
---|---|---|
committer | Robert Helgesson <robert@rycee.net> | 2017-12-26 17:27:21 +0100 |
commit | f0d207f3807c2111532d361c71047e1883595f3a (patch) | |
tree | 8d5ba305fdbad1e3ee9e761573746c4b27ecf10d /modules/services/polybar.nix | |
parent | 7dd09cecda0ea9a84a831259a37609c92fd86652 (diff) |
Add dag library to `config.lib`
Also replace all imports of `dag.nix` by the entry in `config.lib`.
Diffstat (limited to 'modules/services/polybar.nix')
-rw-r--r-- | modules/services/polybar.nix | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/modules/services/polybar.nix b/modules/services/polybar.nix index 2e24f2a94e5..b218c6c6133 100644 --- a/modules/services/polybar.nix +++ b/modules/services/polybar.nix @@ -1,12 +1,13 @@ { config, lib, pkgs, ... }: with lib; -with import ../lib/dag.nix { inherit lib; }; let cfg = config.services.polybar; + dag = config.lib.dag; + toPolybarIni = generators.toINI { mkKeyValue = key: value: let @@ -131,7 +132,7 @@ in }; }; - home.activation.checkPolybar = dagEntryBefore [ "linkGeneration" ] '' + home.activation.checkPolybar = dag.entryBefore [ "linkGeneration" ] '' if ! cmp --quiet \ "${configFile}" \ "$HOME/.config/polybar/config"; then @@ -139,7 +140,7 @@ in fi ''; - home.activation.applyPolybar = dagEntryAfter [ "reloadSystemD" ] '' + home.activation.applyPolybar = dag.entryAfter [ "reloadSystemD" ] '' if [[ -v polybarChanged && -v DISPLAY ]]; then echo "Restarting polybar" ${config.systemd.user.systemctlPath} --user restart polybar.service |