61 lines
2.1 KiB
Nix
61 lines
2.1 KiB
Nix
{
|
|
config,
|
|
pkgs,
|
|
lib,
|
|
...
|
|
}:
|
|
|
|
let
|
|
inherit (lib) mkIf optionals;
|
|
cfg = config.omni.desktop;
|
|
omni = config.omni.lib;
|
|
user = config.omni.user;
|
|
in
|
|
{
|
|
config = mkIf (cfg.enable) {
|
|
home-manager.users.${user} = {
|
|
wayland.windowManager.hyprland.settings = {
|
|
exec-once = [
|
|
# NOTE: do NOT add "waybar" here. Waybar is managed by the
|
|
# systemd user service from `programs.waybar.systemd.enable
|
|
# = true` in modules/desktop/hyprland.nix. Launching it
|
|
# from `exec-once` AS WELL produces two stacked bars on
|
|
# screen. The keybinding to restart waybar
|
|
# (`systemctl --user restart waybar` in bindings.nix) also
|
|
# assumes the systemd-managed instance.
|
|
"gnome-keyring-daemon --start --components=secrets,pkcs11"
|
|
"mako"
|
|
"awww init"
|
|
"nm-applet --indicator"
|
|
"blueman-applet"
|
|
"wl-paste --type text --watch cliphist store"
|
|
"wl-paste --type image --watch cliphist store"
|
|
"${pkgs.polkit_gnome}/libexec/polkit-gnome-authentication-agent-1"
|
|
"mkdir -p ~/Pictures/Screenshots"
|
|
"hypridle"
|
|
"swayosd-server"
|
|
"[workspace 1 silent] ${cfg.defaultTerminal} -e tmux"
|
|
"[workspace 1 silent] ${cfg.defaultBrowser}"
|
|
]
|
|
++ optionals (omni.isEnabled "media") [
|
|
"[workspace 4 silent] spotify"
|
|
]
|
|
++ optionals (omni.isEnabled "communication") [
|
|
"[workspace 5 silent] signal-desktop --password-store=gnome-libsecret"
|
|
"[workspace 5 silent] element-desktop --password-store=gnome-libsecret"
|
|
"[workspace 5 silent] ferdium --password-store=gnome-libsecret"
|
|
# nixpkgs ships the binary as `Telegram` (capital T), not
|
|
# `telegram-desktop`. It's Qt, so it doesn't take the
|
|
# --password-store flag the Electron apps below use.
|
|
"[workspace 5 silent] Telegram"
|
|
];
|
|
|
|
exec =
|
|
[ ]
|
|
++ optionals (cfg.wallpaper != null) [
|
|
"awww img ${toString cfg.wallpaper} --transition-type wipe"
|
|
];
|
|
};
|
|
};
|
|
};
|
|
}
|