feat(desktop): Hyprland, Waybar, autostart/bindings/idle
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
parent
b16707b2ab
commit
6e87d8e186
5 changed files with 1317 additions and 0 deletions
61
modules/desktop/hyprland/autostart.nix
Normal file
61
modules/desktop/hyprland/autostart.nix
Normal file
|
|
@ -0,0 +1,61 @@
|
|||
{
|
||||
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"
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue