mirror of
https://github.com/nix-community/home-manager.git
synced 2025-11-08 11:36:05 +01:00
swww: add extraArgs for swww-daemon
This commit is contained in:
parent
e11d6c321f
commit
627a3932b9
3 changed files with 21 additions and 2 deletions
|
|
@ -13,6 +13,20 @@ in
|
|||
options.services.swww = {
|
||||
enable = lib.mkEnableOption "swww, a Solution to your Wayland Wallpaper Woes";
|
||||
package = lib.mkPackageOption pkgs "swww" { };
|
||||
extraArgs = lib.mkOption {
|
||||
type = lib.types.listOf lib.types.str;
|
||||
default = [ ];
|
||||
example = [
|
||||
"--no-cache"
|
||||
"--layer"
|
||||
"bottom"
|
||||
];
|
||||
description = ''
|
||||
Options given to swww-daemon when the service is run.
|
||||
|
||||
See `swww-daemon --help` for more information.
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
|
|
@ -35,7 +49,7 @@ in
|
|||
};
|
||||
|
||||
Service = {
|
||||
ExecStart = "${lib.getExe' cfg.package "swww-daemon"}";
|
||||
ExecStart = "${lib.getExe' cfg.package "swww-daemon"} ${lib.escapeShellArgs cfg.extraArgs}";
|
||||
Restart = "always";
|
||||
RestartSec = 10;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -3,6 +3,11 @@
|
|||
services.swww = {
|
||||
enable = true;
|
||||
package = config.lib.test.mkStubPackage { outPath = "@swww@"; };
|
||||
extraArgs = [
|
||||
"--no-cache"
|
||||
"--layer"
|
||||
"bottom"
|
||||
];
|
||||
};
|
||||
|
||||
nmt.script = ''
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
WantedBy=graphical-session.target
|
||||
|
||||
[Service]
|
||||
ExecStart=@swww@/bin/swww-daemon
|
||||
ExecStart=@swww@/bin/swww-daemon --no-cache --layer bottom
|
||||
Restart=always
|
||||
RestartSec=10
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue