home-manager: fix standalone config

This commit is contained in:
Leonardo Eugênio 2023-06-02 11:14:27 -03:00
parent 2dd9bea706
commit 073e578141
2 changed files with 6 additions and 3 deletions

View file

@ -133,7 +133,10 @@
homeConfigurations.lelgenio = home-manager.lib.homeManagerConfiguration { homeConfigurations.lelgenio = home-manager.lib.homeManagerConfiguration {
inherit pkgs; inherit pkgs;
extraSpecialArgs = { inherit inputs; }; extraSpecialArgs = {
inherit inputs;
osConfig = {};
};
modules = [ ./user/home.nix ]; modules = [ ./user/home.nix ];
}; };

View file

@ -20,7 +20,7 @@ in
"tray" "tray"
"custom/caffeine" "custom/caffeine"
"pulseaudio" "pulseaudio"
(lib.optional osConfig.services.vpn.enable "custom/vpn") (lib.optional (osConfig.services.vpn.enable or false) "custom/vpn")
"network" "network"
"battery" "battery"
]; ];
@ -110,7 +110,7 @@ in
interval = 1; interval = 1;
tooltip = false; tooltip = false;
}; };
"custom/vpn" = lib.mkIf osConfig.services.vpn.enable { "custom/vpn" = lib.mkIf (osConfig.services.vpn.enable or false) {
format = "{}"; format = "{}";
exec = '' exec = ''
mullvad status | grep "^Connected" > /dev/null \ mullvad status | grep "^Connected" > /dev/null \