we swayin

This commit is contained in:
alisceon 2025-12-01 22:40:14 +01:00
parent 4b859d067d
commit 1fce65acd8
2 changed files with 58 additions and 11 deletions

View file

@ -79,6 +79,10 @@
wrapperFeatures.gtk = true; # Fixes common issues with GTK 3 apps wrapperFeatures.gtk = true; # Fixes common issues with GTK 3 apps
config = { config = {
modifier = "${key_mod}"; modifier = "${key_mod}";
startup = [
{ command = "systemctl --user start libinput-gestures"; always = true; }
{ command = "dbus-update-activation-environment --systemd --all"; always = true; }
];
bars = [{ bars = [{
command = "${pkgs.waybar}/bin/waybar"; command = "${pkgs.waybar}/bin/waybar";
}]; }];
@ -118,8 +122,8 @@
' '
''; '';
# Workspaces # Workspaces
"${key_mod}+Tab" = "workspace next"; "${key_mod}+f" = "fullscreen";
"${key_mod}+Shift+Tab" = "workspace prev"; "${key_mod}+space" = "floating toggle";
"${key_mod}+1" = "workspace number 1"; "${key_mod}+1" = "workspace number 1";
"${key_mod}+2" = "workspace number 2"; "${key_mod}+2" = "workspace number 2";
@ -130,9 +134,7 @@
"${key_mod}+7" = "workspace number 7"; "${key_mod}+7" = "workspace number 7";
"${key_mod}+8" = "workspace number 8"; "${key_mod}+8" = "workspace number 8";
"${key_mod}+9" = "workspace number 9"; "${key_mod}+9" = "workspace number 9";
"${key_mod}+0" = "scratchpad show";
"${key_mod}+Shift+period" = "move container to workspace next; workspace next";
"${key_mod}+Shift+comma" = "move container to workspace prev; workspace prev";
"${key_mod}+Shift+1" = "move container to workspace number 1; workspace 1"; "${key_mod}+Shift+1" = "move container to workspace number 1; workspace 1";
"${key_mod}+Shift+2" = "move container to workspace number 2; workspace 2"; "${key_mod}+Shift+2" = "move container to workspace number 2; workspace 2";
@ -143,6 +145,18 @@
"${key_mod}+Shift+7" = "move container to workspace number 7; workspace 7"; "${key_mod}+Shift+7" = "move container to workspace number 7; workspace 7";
"${key_mod}+Shift+8" = "move container to workspace number 8; workspace 8"; "${key_mod}+Shift+8" = "move container to workspace number 8; workspace 8";
"${key_mod}+Shift+9" = "move container to workspace number 9; workspace 9"; "${key_mod}+Shift+9" = "move container to workspace number 9; workspace 9";
"${key_mod}+Shift+0" = "move container to scratchpad; scratchpad show";
"${key_mod}+Ctrl+1" = "move container to workspace number 1";
"${key_mod}+Ctrl+2" = "move container to workspace number 2";
"${key_mod}+Ctrl+3" = "move container to workspace number 3";
"${key_mod}+Ctrl+4" = "move container to workspace number 4";
"${key_mod}+Ctrl+5" = "move container to workspace number 5";
"${key_mod}+Ctrl+6" = "move container to workspace number 6";
"${key_mod}+Ctrl+7" = "move container to workspace number 7";
"${key_mod}+Ctrl+8" = "move container to workspace number 8";
"${key_mod}+Ctrl+9" = "move container to workspace number 9";
"${key_mod}+Ctrl+0" = "move container to scratchpad";
# Focus # Focus
"${key_mod}+${key_left}" = "focus left"; "${key_mod}+${key_left}" = "focus left";
@ -161,8 +175,8 @@
"${key_mod}+Shift+${key_right}" = "move right"; "${key_mod}+Shift+${key_right}" = "move right";
# System # System
"XF86AudioRaiseVolume" = "exec 'pactl set-sink-volume @DEFAULT_SINK@ +1%'"; "XF86AudioRaiseVolume" = "exec 'pactl set-sink-volume @DEFAULT_SINK@ +3%'";
"XF86AudioLowerVolume" = "exec 'pactl set-sink-volume @DEFAULT_SINK@ -1%'"; "XF86AudioLowerVolume" = "exec 'pactl set-sink-volume @DEFAULT_SINK@ -3%'";
"XF86AudioMute" = "exec 'pactl set-sink-mute @DEFAULT_SINK@ toggle'"; "XF86AudioMute" = "exec 'pactl set-sink-mute @DEFAULT_SINK@ toggle'";
"XF86MonBrightnessUp" = "exec ${pkgs.light}/bin/light -A 10"; "XF86MonBrightnessUp" = "exec ${pkgs.light}/bin/light -A 10";
"XF86MonBrightnessDown" = "exec ${pkgs.light}/bin/light -U 10"; "XF86MonBrightnessDown" = "exec ${pkgs.light}/bin/light -U 10";
@ -235,11 +249,11 @@
events = [ events = [
{ {
event = "before-sleep"; event = "before-sleep";
command = (display "off") + "; " + lock; command = "display off; systemctl --user stop libinput-gestures" + lock;
} }
{ {
event = "after-resume"; event = "after-resume";
command = display "on"; command = "display on; systemctl --user start libinput-gestures";
} }
{ {
event = "lock"; event = "lock";
@ -578,5 +592,35 @@
indicator-thickness = 10; indicator-thickness = 10;
}; # end settings }; # end settings
}; # end swaylock }; # end swaylock
foot = {
enable = true;
server.enable = true;
settings = {
main = {
term = "xterm-256color";
font = "${style_font}:size=${style_font_sz}";
dpi-aware = "no";
};
};
};
}; # end programs }; # end programs
dconf = {
enable = true;
settings = {
"org/gnome/desktop/interface" = {
color-scheme = "prefer-dark";
gtk-theme = "Adwaita-Dark";
};
};
};
xdg.configFile."libinput-gestures.conf".text = ''
gesture swipe left 3 swaymsg workspace prev
gesture swipe right 3 swaymsg workspace next
gesture swipe down 3 swaymsg move container to scratchpad
gesture swipe up 3 swaymsg fullscreen
gesture pinch in 3 swaymsg floating enable
gesture pinch out 3 swaymsg floating disable
gesture pinch in 4 swaymsg kill
gesture swipe up 4 ${lock}
'';
} # end file } # end file

View file

@ -6,7 +6,10 @@
wl-clipboard # wl-copy and wl-paste for copy/paste from stdin / stdout wl-clipboard # wl-copy and wl-paste for copy/paste from stdin / stdout
mako # notification system developed by swaywm maintainer mako # notification system developed by swaywm maintainer
rofi rofi
waybar
libinput
libinput-gestures
wmctrl
]; ];
# enable Sway window manager # enable Sway window manager
@ -43,5 +46,5 @@
}; # end logind }; # end logind
gnome.gnome-keyring.enable = true; gnome.gnome-keyring.enable = true;
}; # end services }; # end services
users.users.alisceon.extraGroups = [ "video" ]; users.users.alisceon.extraGroups = [ "video" "input" ];
} }