This repository has been archived on 2023-08-08. You can view files and clone it, but cannot push or open issues or pull requests.
nil/modules/applications/sway/mako.nix
James Patrick 94613c579e Refactor
2022-03-24 00:00:26 -04:00

66 lines
1.6 KiB
Nix

{ options, config, lib, pkgs, ... }:
let
cfg = config.this.application.mako;
sway = config.this.application.sway;
in with lib; {
options = {
this.application.mako.enable = mkOption {
default = false;
type = with types; bool;
description = "testing one two three";
};
};
config = mkIf cfg.enable {
home-manager.users.james = {
systemd.user.startServices = true;
programs.mako = {
enable = true;
width = 450;
padding = "20,20";
backgroundColor = "#161720ee";
borderColor = "#12151a";
textColor = "#d6e5fb";
defaultTimeout = 8000;
progressColor = "over #d6e5fb";
layer = "overlay";
groupBy = "summary";
extraConfig = ''
[hidden]
background-color=#bfbfbfff
format=+ %h
[urgency=high]
background-color=#1f212eee
border-color=#f0185a00
text-color=#f0185a
ignore-timeout=true
default-timeout=0
[!expiring]
background-color=#555555ff
text-color=#eeeeeeff
[grouped]
format=<b>%s</b> %g\n%b
'';
};
home.packages = with pkgs; [ libnotify ];
};
systemd.user.services.mako = {
enable = true;
description = "Mako foo";
wantedBy = [ "sway-session.target" ];
partOf = [ "graphical-session.target" ];
serviceConfig = {
ExecStart = ''
${pkgs.mako}/bin/mako
'';
RestartSec = 5;
Restart = "always";
};
};
};
}