Revert "Revert "feat(hyprland): extraConfig -> settings""

This reverts commit 4a6922bdff.
This commit is contained in:
jacekpoz 2023-11-28 16:56:44 +01:00
parent 330feeb044
commit 26f40e5d9b
No known key found for this signature in database
GPG key ID: 94E812A8B12AAE3C

View file

@ -13,18 +13,23 @@
inherit (nixpkgs-wayland) wl-clipboard;
inherit (nixpkgs-wayland) swww;
inherit (nixpkgs-wayland) wlsunset;
swaylock = nixpkgs-wayland.swaylock-effects;
swaylock = config.home-manager.users.${config'.username}.programs.swaylock.package;
inherit (inputs.anyrun.packages.${pkgs.system}) anyrun;
hyprcontrib = inputs.hyprcontrib.packages.${pkgs.system};
inherit (inputs.shadower.packages.${pkgs.system}) shadower;
inherit (inputs.hyprland.packages.${pkgs.system}) hyprland;
in {
in rec {
options.myOptions.programs.hyprland = {
enable = mkEnableOption "enable hiper ląd";
startupSound = mkOption {
type = types.path;
description = "sound to play on hyprland startup";
};
tearing = mkOption {
type = types.bool;
description = "enable tearing";
default = false;
};
};
disabledModules = [ "programs/hyprland.nix" ];
@ -54,302 +59,347 @@ in {
enable = true;
package = inputs.hyprland.packages.${pkgs.system}.hyprland;
plugins = [
#inputs.hyprland-plugins.packages.${pkgs.system}.csgo-vulkan-fix
inputs.hyprland-plugins.packages.${pkgs.system}.csgo-vulkan-fix
inputs.split-monitor-workspaces.packages.${pkgs.system}.split-monitor-workspaces
];
extraConfig = ''
#laptop
monitor=eDP-1,2560x1440@165,0x0,1
#second monitor
monitor=HDMI-A-1,2560x1440@144,2560x0,1
settings = {
"$mainMod" = "SUPER";
workspace = 1, monitor:eDP-1, default:true
workspace = 2, monitor:eDP-1
workspace = 3, monitor:eDP-1
workspace = 4, monitor:eDP-1
workspace = 5, monitor:eDP-1
workspace = 6, monitor:eDP-1
workspace = 7, monitor:eDP-1
workspace = 8, monitor:eDP-1
workspace = 9, monitor:eDP-1
workspace = 10, monitor:eDP-1
monitor = [
# laptop
"eDP-1, 2560x1440@165, 0x0, 1.5"
# second monitor
"HDMI-A-1, 2560x1440@144, ${toString (2560 / 1.5)}x0, 1"
];
workspace = 11, monitor:HDMI-A-1, default:true
workspace = 12, monitor:HDMI-A-1
workspace = 13, monitor:HDMI-A-1
workspace = 14, monitor:HDMI-A-1
workspace = 15, monitor:HDMI-A-1
workspace = 16, monitor:HDMI-A-1
workspace = 17, monitor:HDMI-A-1
workspace = 18, monitor:HDMI-A-1
workspace = 19, monitor:HDMI-A-1
workspace = 20, monitor:HDMI-A-1
workspace = [
# laptop
"1, monitor:eDP-1, default:true"
"2, monitor:eDP-1"
"3, monitor:eDP-1"
"4, monitor:eDP-1"
"5, monitor:eDP-1"
"6, monitor:eDP-1"
"7, monitor:eDP-1"
"8, monitor:eDP-1"
"9, monitor:eDP-1"
"10, monitor:eDP-1"
workspace = special:btop, decorate:false
workspace = special:amdgpu_top, decorate:false
workspace = special:pipewire, decorate:false
workspace = special:nixos,decorate:false
workspace = special:rog,decorate:false
workspace = special:keepassxc,decorate:false
# second monitor
"11, monitor:HDMI-A-1, default:true"
"12, monitor:HDMI-A-1"
"13, monitor:HDMI-A-1"
"14, monitor:HDMI-A-1"
"15, monitor:HDMI-A-1"
"16, monitor:HDMI-A-1"
"17, monitor:HDMI-A-1"
"18, monitor:HDMI-A-1"
"19, monitor:HDMI-A-1"
"20, monitor:HDMI-A-1"
input {
kb_layout=pl,ru
kb_variant=
kb_model=
kb_options=
kb_rules=
# scratchpads
"special:btop, decorate:false"
"special:amdgpu_top, decorate:false"
"special:pipewire, decorate:false"
"special:nixos, decorate:false"
"special:rog, decorate:false"
"special:keepassxc, decorate:false"
];
follow_mouse=1
touchpad {
disable_while_typing=false
}
input = {
kb_layout = "pl,ru";
kb_variant = "";
kb_model = "";
kb_options = "";
kb_rules = "";
repeat_rate = 50
repeat_delay = 250
}
follow_mouse = true;
touchpad = {
disable_while_typing = false;
};
general {
sensitivity=1.0 # for mouse cursor
repeat_rate = 50;
repeat_delay = 250;
};
gaps_in=5
gaps_out=5
#gaps_in=0
#gaps_out=0
border_size=2
#border_size=1
general = {
sensitivity = 1.0;
apply_sens_to_raw=0 # whether to apply the sensitivity to raw input (e.g. used by games where you aim using your mouse)
gaps_in = 5;
gaps_out = 5;
border_size = 2;
#no_border_on_floating=true
apply_sens_to_raw = 0;
#allow_tearing=true
}
#no_border_on_floating = true;
allow_tearing = mkIf cfg.tearing true;
#env = WLR_DRM_NO_ATOMIC,1
#windowrulev2 = immediate, title:^(osu!)$
"col.active_border" = "0xFFF5C2E7";
"col.inactive_border" = "0xFF45475A";
#col.group_border_active = "0xFFA6E3A1";
#col.group_border = "0xFF45475A";
};
decoration {
#rounding=0
rounding=10
blur {
enabled=1
size=3
passes=2
}
env = [
mkIf cfg.tearing "WLR_DRM_NO_ATOMIC,1"
];
drop_shadow=1
shadow_range=15
shadow_render_power=2
shadow_ignore_window=1
shadow_offset= 2 4
shadow_scale=1
}
decoration = {
rounding = 10;
blur = {
enabled = true;
size = 3;
passes = 2;
};
gestures {
workspace_swipe=1
workspace_swipe_distance=200
workspace_swipe_invert=1
workspace_swipe_min_speed_to_force=20
workspace_swipe_cancel_ratio=0.5
}
drop_shadow = 1;
shadow_range = 15;
shadow_render_power = 2;
shadow_ignore_window = 1;
shadow_offset = "2 4";
shadow_scale = 1;
bezier=dupa, 0.1, 0.9, 0.1, 1.05
"col.shadow" = "0xAF1E1E2E";
};
animations {
enabled=1
animation=windows,1,4,dupa,popin
animation=windowsOut,1,7,dupa,slide
animation=border,1,15,default
animation=fade,1,10,default
animation=workspaces,1,5,dupa,slidevert
}
gestures = {
workspace_swipe = 1;
workspace_swipe_distance = 200;
workspace_swipe_invert = 1;
workspace_swipe_min_speed_to_force = 20;
workspace_swipe_cancel_ratio = 0.5;
};
dwindle {
no_gaps_when_only=1
}
bezier = [
"dupa, 0.1, 0.9, 0.1, 1.05"
];
misc {
enable_swallow=0
swallow_regex=foot
focus_on_activate=true
vrr=1
animate_manual_resizes=false
animate_mouse_windowdragging=false
force_default_wallpaper=0
}
animations = {
enabled = true;
animation = [
"windows, 1, 4, dupa, popin"
"windowsOut, 1, 7, dupa, slide"
"border, 1, 15, default"
"fade, 1, 10, default"
"workspaces, 1, 5, dupa, slidevert"
];
};
windowrulev2 = float, title:^(.*)(Tor Browser)(.*)$
windowrulev2 = float, class:^(mullvadbrowser)$
windowrulev2 = float, class:^(foot)$
windowrulev2 = float, class:^(mpv)$
windowrulev2 = float, class:^(imv)$
windowrulev2 = float, class:^(Vieb)$
windowrulev2 = float, title:^(Picture-in-Picture)$
windowrulev2 = float, title:^(.*)(Choose User Profile)(.*)$
windowrulev2 = float, title:^(blob:null/)(.*)$
dwindle = {
no_gaps_when_only = true;
};
windowrulev2 = float, class:^(xdg-desktop-portal-gtk)$
windowrulev2 = float, class:^(code), title: ^(Open*)
windowrulev2 = size 70% 70%, class:^(code), title: ^(Open*)
windowrulev2 = center, class: ^(code), title: ^(Open*)
windowrulev2 = float, class:^(org.keepassxc.KeePassXC)$
windowrulev2 = size 960 670, title:^(ROG Control Center)$
misc = {
enable_swallow = false;
swallow_regex = "foot";
focus_on_activate = true;
vrr = true;
animate_manual_resizes = false;
animate_mouse_windowdragging = false;
force_default_wallpaper = 0;
};
bind = SUPER, RETURN, exec, ${foot}/bin/${if config.myOptions.programs.foot.server then "footclient" else "foot"}
bind = SUPER, W, exec, ${removeSuffix " %U" config.home-manager.users.${config'.username}.xdg.desktopEntries.firefox-schizo.exec}
bind = SUPERSHIFT, W, exec, ${removeSuffix " %U" config.home-manager.users.${config'.username}.xdg.desktopEntries.firefox-unschizo.exec}
bind = SUPER, Q, killactive
bind = SUPER, F, fullscreen, 0
bind = SUPER, M, fullscreen, 1
bind = SUPER, D, exec, ${pkgs.procps}/bin/pkill anyrun || ${anyrun}/bin/anyrun
bind = SUPER, SPACE, togglefloating,
bind = SUPERSHIFT, C, centerwindow
bind = SUPERCONTROL, R, bringactivetotop
binde = SUPER, H, movefocus, l
binde = SUPER, J, movefocus, d
binde = SUPER, K, movefocus, u
binde = SUPER, L, movefocus, r
binde = SUPERCTRL, J, focusmonitor, l
binde = SUPERCTRL, K, focusmonitor, r
bind = SUPER, 1, split-workspace, 1
bind = SUPER, 2, split-workspace, 2
bind = SUPER, 3, split-workspace, 3
bind = SUPER, 4, split-workspace, 4
bind = SUPER, 5, split-workspace, 5
bind = SUPER, 6, split-workspace, 6
bind = SUPER, 7, split-workspace, 7
bind = SUPER, 8, split-workspace, 8
bind = SUPER, 9, split-workspace, 9
bind = SUPER, 0, split-workspace, 10
bind = SUPERSHIFT, 1, split-movetoworkspacesilent, 1
bind = SUPERSHIFT, 2, split-movetoworkspacesilent, 2
bind = SUPERSHIFT, 3, split-movetoworkspacesilent, 3
bind = SUPERSHIFT, 4, split-movetoworkspacesilent, 4
bind = SUPERSHIFT, 5, split-movetoworkspacesilent, 5
bind = SUPERSHIFT, 6, split-movetoworkspacesilent, 6
bind = SUPERSHIFT, 7, split-movetoworkspacesilent, 7
bind = SUPERSHIFT, 8, split-movetoworkspacesilent, 8
bind = SUPERSHIFT, 9, split-movetoworkspacesilent, 9
bind = SUPERSHIFT, 0, split-movetoworkspacesilent, 10
bindle = , XF86MonBrightnessUp, exec, ~/Scripts/notif_brightness.sh set +5%
bindle = , XF86MonBrightnessDown, exec, ~/Scripts/notif_brightness.sh set 5%-
bindl = , XF86AudioMedia, exec, ${pkgs.playerctl}/bin/playerctl play-pause
bindl = , XF86AudioPlay, exec, ${pkgs.playerctl}/bin/playerctl play-pause
bindl = , XF86AudioStop, exec, ${pkgs.playerctl}/bin/playerctl stop
bindl = , XF86AudioPrev, exec, ${pkgs.playerctl}/bin/playerctl previous
bindl = , XF86AudioNext, exec, ${pkgs.playerctl}/bin/playerctl next
bindle = , XF86AudioRaiseVolume, exec, ~/Scripts/notif_volume.sh -ui 5
bindle = , XF86AudioLowerVolume, exec, ~/Scripts/notif_volume.sh -ud 5
bindl = , XF86AudioMute, exec, ~/Scripts/notif_volume.sh --toggle-mute
windowrulev2 = [
mkIf cfg.tearing "immediate, title:^(osu!)$"
"float, title:^(.*)(Tor Browser)(.*)$"
"float, class:^(mullvadbrowser)$"
"float, class:^(foot)$"
"float, class:^(mpv)$"
"float, class:^(imv)$"
"float, class:^(Vieb)$"
"float, title:^(Picture-in-Picture)$"
"float, title:^(.*)(Choose User Profile)(.*)$"
"float, title:^(blob:null/)(.*)$"
bind = SUPER, S, exec, ${hyprcontrib.grimblast}/bin/grimblast save area - | ${pkgs.coreutils-full}/bin/tee "$(${pkgs.xdg-user-dirs}/bin/xdg-user-dir PICTURES)/Screenshots/$(date +'screenshot-%Y%m%d%H%M%S.png')" | ${wl-clipboard}/bin/wl-copy && ${pkgs.libnotify}/bin/notify-send "Screenshot taken"
bind = SUPERSHIFT, S, exec, ${hyprcontrib.grimblast}/bin/grimblast save area - | ${shadower}/bin/shadower | ${pkgs.coreutils-full}/bin/tee "$(${pkgs.xdg-user-dirs}/bin/xdg-user-dir PICTURES)/Screenshots/$(date +'screenshot-%Y%m%d%H%M%S.png')" | ${wl-clipboard}/bin/wl-copy && ${pkgs.libnotify}/bin/notify-send "Screenshot taken (shadower)"
bind = SUPERCONTROL, S, exec, ${hyprcontrib.grimblast}/bin/grimblast save area - | ${pkgs.swappy}/bin/swappy -f - -o - | ${pkgs.coreutils-full}/bin/tee "$(${pkgs.xdg-user-dirs}/bin/xdg-user-dir PICTURES)/Screenshots/$(date +'screenshot-%Y%m%d%H%M%S.png')" | ${wl-clipboard}/bin/wl-copy && ${pkgs.libnotify}/bin/notify-send "Screenshot taken"
bind = SUPERSHIFTCONTROL, S, exec, ${hyprcontrib.grimblast}/bin/grimblast save area - | ${pkgs.swappy}/bin/swappy -f - -o - | ${shadower}/bin/shadower | ${pkgs.coreutils-full}/bin/tee "$(${pkgs.xdg-user-dirs}/bin/xdg-user-dir PICTURES)/Screenshots/$(date +'screenshot-%Y%m%d%H%M%S.png')" | ${wl-clipboard}/bin/wl-copy && ${pkgs.libnotify}/bin/notify-send "Screenshot taken (shadower)"
"float, class:^(xdg-desktop-portal-gtk)$"
"float, class:^(code), title: ^(Open*)"
"size 70% 70%, class:^(code), title: ^(Open*)"
"center, class: ^(code), title: ^(Open*)"
"float, class:^(org.keepassxc.KeePassXC)$"
"size 960 670, title:^(ROG Control Center)$"
];
bind = SUPERSHIFT, R, exec, ${hyprland}/bin/hyprctl reload
bind = SUPER, P, pin
bind = , XF86Launch1, togglespecialworkspace, rog
binde = , XF86Launch3, exec, ${pkgs.asusctl}/bin/asusctl led-mode -n
bind = , XF86Launch4, exec, ${pkgs.asusctl}/bin/asusctl profile -n
binde = , XF86KbdBrightnessUp, exec, ${pkgs.asusctl}/bin/asusctl -n
binde = , XF86KbdBrightnessDown, exec, ${pkgs.asusctl}/bin/asusctl -p
bind = , XF86TouchpadToggle, exec,
#bind = SUPER, T, exec, grim -g "$(slurp)" -t ppm - | tesseract -l pol - - | wl-copy && notify-send "Copied text: " "\"$(wl-paste)\""
bind = SUPER, SEMICOLON, exec, ~/.config/rofi/powermenu/type-2/powermenu.sh
bind = SUPER, G, togglegroup
binde = SUPERSHIFT, G, changegroupactive, f
binde = SUPERCONTROL, G, changegroupactive, b
bind = SUPERCONTROL, X, exec, ${pkgs.systemd}/bin/systemctl --user restart xdg-desktop-portal-hyprland
bind = SUPERSHIFT, X, exec, ${hyprland}/bin/hyprctl kill
bind = SUPER, B, togglespecialworkspace, btop
bind = SUPER, A, togglespecialworkspace, amdgpu_top
bind = SUPER, V, togglespecialworkspace, pipewire
bind = SUPER, N, togglespecialworkspace, nixos
bind = SUPER, R, togglespecialworkspace, rog
bind = SUPER, X, togglespecialworkspace, keepassxc
bind = SUPER, C, exec, ${swaylock}/bin/swaylock
bind = SUPERCONTROL, B, exec, ${pkgs.systemd}/bin/systemctl is-active --user waybar && ${pkgs.systemd}/bin/systemctl stop --user waybar || ${pkgs.systemd}/bin/systemctl start --user waybar
bind = [
"$mainMod, RETURN, exec, ${foot}/bin/${if config.myOptions.programs.foot.server then "footclient" else "foot"}"
"$mainMod, W, exec, ${removeSuffix " %U" config.home-manager.users.${config'.username}.xdg.desktopEntries.firefox-schizo.exec}"
"$mainMod SHIFT, W, exec, ${removeSuffix " %U" config.home-manager.users.${config'.username}.xdg.desktopEntries.firefox-unschizo.exec}"
"$mainMod, Q, killactive"
"$mainMod, F, fullscreen, 0"
"$mainMod, M, fullscreen, 1"
"$mainMod, D, exec, ${pkgs.procps}/bin/pkill anyrun || ${anyrun}/bin/anyrun"
"$mainMod, SPACE, togglefloating, active"
"$mainMod SHIFT, C, centerwindow"
"$mainMod CONTROL, R, bringactivetotop"
"$mainMod, P, pin"
# workspaces
"$mainMod, 1, split-workspace, 1"
"$mainMod, 2, split-workspace, 2"
"$mainMod, 3, split-workspace, 3"
"$mainMod, 4, split-workspace, 4"
"$mainMod, 5, split-workspace, 5"
"$mainMod, 6, split-workspace, 6"
"$mainMod, 7, split-workspace, 7"
"$mainMod, 8, split-workspace, 8"
"$mainMod, 9, split-workspace, 9"
"$mainMod, 0, split-workspace, 10"
"$mainMod SHIFT, 1, split-movetoworkspacesilent, 1"
"$mainMod SHIFT, 2, split-movetoworkspacesilent, 2"
"$mainMod SHIFT, 3, split-movetoworkspacesilent, 3"
"$mainMod SHIFT, 4, split-movetoworkspacesilent, 4"
"$mainMod SHIFT, 5, split-movetoworkspacesilent, 5"
"$mainMod SHIFT, 6, split-movetoworkspacesilent, 6"
"$mainMod SHIFT, 7, split-movetoworkspacesilent, 7"
"$mainMod SHIFT, 8, split-movetoworkspacesilent, 8"
"$mainMod SHIFT, 9, split-movetoworkspacesilent, 9"
"$mainMod SHIFT, 0, split-movetoworkspacesilent, 10"
# screenshots
"$mainMod, S, exec, ${hyprcontrib.grimblast}/bin/grimblast save area - | ${pkgs.coreutils-full}/bin/tee \"$(${pkgs.xdg-user-dirs}/bin/xdg-user-dir PICTURES)/Screenshots/$(date +'screenshot-%Y%m%d%H%M%S.png')\" | ${wl-clipboard}/bin/wl-copy && ${pkgs.libnotify}/bin/notify-send \"Screenshot taken\""
"$mainMod SHIFT, S, exec, ${hyprcontrib.grimblast}/bin/grimblast save area - | ${shadower}/bin/shadower | ${pkgs.coreutils-full}/bin/tee \"$(${pkgs.xdg-user-dirs}/bin/xdg-user-dir PICTURES)/Screenshots/$(date +'screenshot-%Y%m%d%H%M%S.png')\" | ${wl-clipboard}/bin/wl-copy && ${pkgs.libnotify}/bin/notify-send \"Screenshot taken (shadower)\""
"$mainMod CONTROL, S, exec, ${hyprcontrib.grimblast}/bin/grimblast save area - | ${pkgs.swappy}/bin/swappy -f - -o - | ${pkgs.coreutils-full}/bin/tee \"$(${pkgs.xdg-user-dirs}/bin/xdg-user-dir PICTURES)/Screenshots/$(date +'screenshot-%Y%m%d%H%M%S.png')\" | ${wl-clipboard}/bin/wl-copy && ${pkgs.libnotify}/bin/notify-send \"Screenshot taken\""
"$mainMod SHIFT CONTROL, S, exec, ${hyprcontrib.grimblast}/bin/grimblast save area - | ${pkgs.swappy}/bin/swappy -f - -o - | ${shadower}/bin/shadower | ${pkgs.coreutils-full}/bin/tee \"$(${pkgs.xdg-user-dirs}/bin/xdg-user-dir PICTURES)/Screenshots/$(date +'screenshot-%Y%m%d%H%M%S.png')\" | ${wl-clipboard}/bin/wl-copy && ${pkgs.libnotify}/bin/notify-send \"Screenshot taken (shadower)\""
"$mainMod SHIFT, R, exec, ${hyprland}/bin/hyprctl reload"
bindm = SUPER, mouse:272, movewindow
bindm = SUPER, mouse:273, resizewindow
", XF86Launch3, exec, ${pkgs.asusctl}/bin/asusctl led-mode -n"
", XF86Launch4, exec, ${pkgs.asusctl}/bin/asusctl profile -n"
# TODO what the fuck is this
", XF86TouchpadToggle, exec, "
# TODO fix this maybe
"$mainMod, T, exec, grim -g \"$(slurp)\" -t ppm - | tesseract -l pol - - | wl-copy && notify-send \"Copied text: \" \"\\\"$(wl-paste)\\\"\""
# TODO fix this
"$mainMod, SEMICOLON, exec, ~/.config/rofi/powermenu/type-2/powermenu.sh"
"$mainMod, G, togglegroup"
# this sometimes fixes the portal
"$mainMod CONTROL, X, exec, ${pkgs.systemd}/bin/systemctl --user restart xdg-desktop-portal-hyprland"
"$mainMod SHIFT, X, exec, ${hyprland}/bin/hyprctl kill"
# scratchpad binds
"$mainMod, B, togglespecialworkspace, btop"
"$mainMod, A, togglespecialworkspace, amdgpu_top"
"$mainMod, V, togglespecialworkspace, pipewire"
"$mainMod, N, togglespecialworkspace, nixos"
", XF86Launch1, togglespecialworkspace, rog"
"$mainMod, R, togglespecialworkspace, rog"
"$mainMod, X, togglespecialworkspace, keepassxc"
# toggle waybar
"$mainMod CONTROL, B, exec, ${pkgs.systemd}/bin/systemctl is-active --user waybar && ${pkgs.systemd}/bin/systemctl stop --user waybar || ${pkgs.systemd}/bin/systemctl start --user waybar"
"$mainMod, C, exec, ${swaylock}/bin/swaylock"
];
binds {
pass_mouse_when_bound=0
}
# repeat
binde = [
# window / monitor focus
"$mainMod, H, movefocus, l"
"$mainMod, J, movefocus, d"
"$mainMod, K, movefocus, u"
"$mainMod, L, movefocus, r"
"$mainMod CONTROL, J, focusmonitor, l"
"$mainMod CONTROL, K, focusmonitor, r"
${if cfg.startupSound != "" then "exec-once=${pkgs.mpv}/bin/mpv --no-video --volume=100 ~/${config.home-manager.users.${config'.username}.xdg.dataFile."hypr/startup_sound".target}" else ""}
# keyboard brightness
", XF86KbdBrightnessUp, exec, ${pkgs.asusctl}/bin/asusctl -n"
", XF86KbdBrightnessDown, exec, ${pkgs.asusctl}/bin/asusctl -p"
exec-once=${pkgs.systemd}/bin/systemctl start --user waybar.service
exec=${pkgs.systemd}/bin/systemctl restart --user waybar.service
"$mainMod SHIFT, G, changegroupactive, f"
"$mainMod CONTROL, G, changegroupactive, b"
];
exec=${pkgs.procps}/bin/pkill btop
exec=${pkgs.procps}/bin/pkill amdgpu_top
exec=${pkgs.procps}/bin/pkill helvum
exec=${pkgs.procps}/bin/pkill pavucontrol
# locked
bindl = [
", XF86AudioMedia, exec, ${pkgs.playerctl}/bin/playerctl play-pause"
", XF86AudioPlay, exec, ${pkgs.playerctl}/bin/playerctl play-pause"
", XF86AudioStop, exec, ${pkgs.playerctl}/bin/playerctl stop"
", XF86AudioPrev, exec, ${pkgs.playerctl}/bin/playerctl previous"
", XF86AudioNext, exec, ${pkgs.playerctl}/bin/playerctl next"
", XF86AudioMute, exec, ~/Scripts/notif_volume.sh --toggle-mute"
];
exec=[workspace special:btop silent;tile] ${foot}/bin/foot -e ${pkgs.btop}/bin/btop
exec=[workspace special:amdgpu_top silent;tile] ${pkgs.amdgpu_top}/bin/amdgpu_top --gui -i 0
exec=[workspace special:amdgpu_top silent;tile] ${pkgs.amdgpu_top}/bin/amdgpu_top --gui -i 1
exec=[workspace special:pipewire silent;tile] ${pkgs.helvum}/bin/helvum
exec=[workspace special:pipewire silent;tile] ${pkgs.pavucontrol}/bin/pavucontrol
exec-once=[workspace special:nixos silent;tile] cd ~/niksos; ${foot}/bin/foot
exec-once=[workspace special:rog silent;tile] ${pkgs.asusctl}/bin/rog-control-center
exec-once=[workspace special:keepassxc silent;tile] ${pkgs.keepassxc}/bin/keepassxc
# locked + repeat
bindle = [
", XF86MonBrightnessUp, exec, ~/Scripts/notif_brightness.sh set +5%"
", XF86MonBrightnessDown, exec, ~/Scripts/notif_brightness.sh set 5%-"
", XF86AudioRaiseVolume, exec, ~/Scripts/notif_volume.sh -ui 5"
", XF86AudioLowerVolume, exec, ~/Scripts/notif_volume.sh -ud 5"
];
${if config.myOptions.programs.foot.server then "exec-once=sleep 0.5 && ${pkgs.systemd}/bin/systemctl --user restart foot.service" else ""}
exec-once=${hyprland}/bin/hyprctl setcursor Bibata-Modern-Classic 24
# mouse
bindm = [
"$mainMod, mouse:272, movewindow"
"$mainMod, mouse:273, resizewindow"
];
#exec-once=${wl-clipboard}/bin/wl-paste --watch cliphist store
binds = {
pass_mouse_when_bound = false;
};
exec-once=${swww}/bin/swww init
exec=sleep 0.5 && ${swww}/bin/swww img -o eDP-1 ~/catppuccin-wall0.png
exec=sleep 0.5 && ${swww}/bin/swww img -o HDMI-A-1 ~/catppuccin-wall1.png
exec-once = [
mkIf (cfg.startupSound != "") "exec-once=${pkgs.mpv}/bin/mpv --no-video --volume=100 ~/${config.home-manager.users.${config'.username}.xdg.dataHome}/hypr/startup_sound"
"${pkgs.systemd}/bin/systemctl start --user waybar.service"
exec-once=${wlsunset}/bin/wlsunset -S 06:00 -s 20:00
# run persistent special workspace windows
"[workspace special:nixos silent;tile] cd ~/niksos; ${foot}/bin/foot"
"[workspace special:rog silent;tile] ${pkgs.asusctl}/bin/rog-control-center"
"[workspace special:keepassxc silent;tile] ${pkgs.keepassxc}/bin/keepassxc"
exec-once=${pkgs.networkmanagerapplet}/bin/nm-applet --indicator
mkIf config.myOptions.programs.foot.server "sleep 0.5 && ${pkgs.systemd}/bin/systemctl --user restart foot.service"
exec-once=${pkgs.blueman}/bin/blueman-applet
"${hyprland}/bin/hyprctl setcursor Bibata-Modern-Classic 24"
#exec-once=fcitx5
# TODO do something with this
#"${wl-clipboard}/bin/wl-paste --watch cliphist store"
exec-once=${pkgs.systemd}/bin/systemctl --user import-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP
exec-once=${pkgs.dbus}/bin/dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP=$XDG_CURRENT_DESKTOP
"${swww}/bin/swww init"
"${wlsunset}/bin/wlsunset -S 06:00 -s 20:00"
"${pkgs.networkmanagerapplet}/bin/nm-applet --indicator"
"${pkgs.blueman}/bin/blueman-applet"
# TODO fix fcitx5
#"fcitx5"
# TODO do these do anything anymore
"${pkgs.systemd}/bin/systemctl --user import-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP"
"${pkgs.dbus}/bin/dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP=$XDG_CURRENT_DESKTOP"
];
# no black border on grimblast screenshots
layerrule = noanim, ^(selection)$
exec = [
# kill (almost) everything on special workspaces
"${pkgs.procps}/bin/pkill btop"
"${pkgs.procps}/bin/pkill amdgpu_top"
"${pkgs.procps}/bin/pkill helvum"
"${pkgs.procps}/bin/pkill pavucontrol"
# and run it all again
"[workspace special:btop silent;tile] ${foot}/bin/foot -e ${pkgs.btop}/bin/btop"
"[workspace special:amdgpu_top silent;tile] ${pkgs.amdgpu_top}/bin/amdgpu_top --gui -i 0"
"[workspace special:amdgpu_top silent;tile] ${pkgs.amdgpu_top}/bin/amdgpu_top --gui -i 1"
"[workspace special:pipewire silent;tile] ${pkgs.helvum}/bin/helvum"
"[workspace special:pipewire silent;tile] ${pkgs.pavucontrol}/bin/pavucontrol"
layerrule = blur, ^(waybar)$
layerrule = blur, ^(eww)$
# wait a bit then set the wallpapers
"sleep 0.5 && ${swww}/bin/swww img -o eDP-1 ~/catppuccin-wall0.png"
"sleep 0.5 && ${swww}/bin/swww img -o HDMI-A-1 ~/catppuccin-wall1.png"
];
# temporary fix to swaylock screenshoting rofi before locking
layerrule = noanim, ^(rofi)$
layerrule = [
# no black border on grimblast screenshots
"noanim, ^(selection)$"
layerrule = blur, ^(anyrun)$
"blur, ^(waybar)$"
"blur, ^(eww)$"
general {
col.active_border=0xFFF5C2E7
col.inactive_border=0xFF45475A
#col.group_border_active=0xFFA6E3A1
#col.group_border=0xFF45475A
}
# TODO maybe this isn't needed
# temporary fix to swaylock screenshoting rofi before locking
#"noanim, ^(rofi)$"
decoration {
col.shadow=0xAF1E1E2E
}
"blur, ^(anyrun)$"
];
plugin {
csgo-vulkan-fix {
res_w = 2560
res_h = 1440
}
split-monitor-workspaces {
count = 10
keep_focused = true
}
}
'';
plugin = {
csgo-vulkan-fix = {
res_w = 2560;
res_h = 1440;
};
split-monitor-workspaces = {
count = 10;
keep_focused = true;
};
};
};
};
};
};