nixos-config/home-manager/modules/swaynotificationcenter/default.nix
Erwin Boskma 4cd0f83ce8
Some checks failed
/ check (push) Failing after 2m46s
Run nixfmt
2024-02-05 11:46:52 +01:00

36 lines
787 B
Nix

{
pkgs,
config,
lib,
...
}:
with lib;
let
cfg = config.eboskma.programs.swaynotificationcenter;
settingsFormat = pkgs.formats.json { };
in
{
options.eboskma.programs.swaynotificationcenter = {
enable = mkEnableOption "SwayNotificationCenter";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [ swaynotificationcenter ];
xdg.configFile."swaync/config.json" = {
source = settingsFormat.generate "swaync-config.json" {
"$schema" = "${pkgs.swaynotificationcenter}/etc/xdg/swaync/configScheme.json";
scripts = { };
widgets = [
"title"
"dnd"
"inhibitors"
"mpris"
"volume"
"notifications"
];
notification-2fa-action = false;
};
};
};
}