From 3eacc6bdf8819a275362d99eacefb9220347554b Mon Sep 17 00:00:00 2001 From: Ezri Brimhall Date: Mon, 11 Mar 2024 12:53:01 -0600 Subject: [PATCH] Localized input config, fixed some local workspace config --- .config/sway/config | 23 +- .config/sway/config~ | 260 ------------------ ...isplay-arrangement.conf##hostname.normandy | 4 +- .config/sway/input.conf##default | 21 ++ .config/sway/input.conf##hostname.normandy | 21 ++ .../sway/workspaces.json##hostname.normandy | 87 +++--- 6 files changed, 91 insertions(+), 325 deletions(-) delete mode 100644 .config/sway/config~ create mode 100644 .config/sway/input.conf##default create mode 100644 .config/sway/input.conf##hostname.normandy diff --git a/.config/sway/config b/.config/sway/config index 0194fc0..5f83b6d 100644 --- a/.config/sway/config +++ b/.config/sway/config @@ -7,6 +7,7 @@ # locations: # - `display-arrangement.conf` -- display arrangement # - `workspace-arrangement.conf` -- workspace arrangement +# - `input.conf` -- input configuration (most devices should use the ##default variant) # - `local-config.d/*.conf` -- additional device-specific configuration files # These files should be symlinks managed by `yadm`. @@ -187,27 +188,7 @@ bindsym { # Input Configuration # ### ### -## Keyboard Settings -input type:keyboard { - xkb_numlock enabled - xkb_options compose:caps - xkb_file ~/.config/sway/keymap.xkb -} - -## Touchpad Settings -input type:touchpad { - tap enabled - natural_scroll enabled - dwt disabled - drag enabled - accel_profile adaptive -} - -## Mouse Settings -input type:pointer { - accel_profile flat - natural_scroll disabled -} +include input.conf ### ### # Service Management # diff --git a/.config/sway/config~ b/.config/sway/config~ deleted file mode 100644 index 4908ebb..0000000 --- a/.config/sway/config~ +++ /dev/null @@ -1,260 +0,0 @@ -#### #### -## Triskelion sway Config File ## -#### #### - -### ### -# Display settings # -### ### - -# This section controls how connected displays are treated - -# Set monitor vars -set $leftdisplay DP-1 -set $rightdisplay DP-2 - -output { - $leftdisplay pos 0 0 mode 1920x1080 - $rightdisplay pos 1920 0 mode 1920x1080 - * bg '#1e1e1e' solid_color -} - -### ### -# Window Manager settings # -### ### - -# This section controls how the window manager functions. It does -# not include keybinds that are not directly related to the window -# manager's window management functions. - -set $mod Mod4 -set $alt Mod1 - -# Set font -font pango:Source Code Pro 8 - -# Reload configuration -bindsym $mod+Shift+r reload - -# Exit -bindsym $mod+Shift+e exit - -### ### -# Window Management Settings # -### ### - -# This section controls window behavior and management keybinds. -# It also includes the resize mode. - -# Set keybinds to switch workspaces -bindsym $mod+1 exec swaymsg workspace $(i3-sensible-workspaces 1 ) -bindsym $mod+2 exec swaymsg workspace $(i3-sensible-workspaces 2 ) -bindsym $mod+3 exec swaymsg workspace $(i3-sensible-workspaces 3 ) -bindsym $mod+4 exec swaymsg workspace $(i3-sensible-workspaces 4 ) -bindsym $mod+5 exec swaymsg workspace $(i3-sensible-workspaces 5 ) -bindsym $mod+6 exec swaymsg workspace $(i3-sensible-workspaces 6 ) -bindsym $mod+7 exec swaymsg workspace $(i3-sensible-workspaces 7 ) -bindsym $mod+8 exec swaymsg workspace $(i3-sensible-workspaces 8 ) -bindsym $mod+9 exec swaymsg workspace $(i3-sensible-workspaces 9 ) -bindsym $mod+0 exec swaymsg workspace $(i3-sensible-workspaces 10) - -# Set keybinds to move windows between workspaces -bindsym $mod+Shift+1 exec swaymsg move container to workspace $(i3-sensible-workspaces 1 ) -bindsym $mod+Shift+2 exec swaymsg move container to workspace $(i3-sensible-workspaces 2 ) -bindsym $mod+Shift+3 exec swaymsg move container to workspace $(i3-sensible-workspaces 3 ) -bindsym $mod+Shift+4 exec swaymsg move container to workspace $(i3-sensible-workspaces 4 ) -bindsym $mod+Shift+5 exec swaymsg move container to workspace $(i3-sensible-workspaces 5 ) -bindsym $mod+Shift+6 exec swaymsg move container to workspace $(i3-sensible-workspaces 6 ) -bindsym $mod+Shift+7 exec swaymsg move container to workspace $(i3-sensible-workspaces 7 ) -bindsym $mod+Shift+8 exec swaymsg move container to workspace $(i3-sensible-workspaces 8 ) -bindsym $mod+Shift+9 exec swaymsg move container to workspace $(i3-sensible-workspaces 9 ) -bindsym $mod+Shift+0 exec swaymsg move container to workspace $(i3-sensible-workspaces 10) - -# Bind workspaces to monitors -workspace 1 output $leftdisplay -workspace 2 output $leftdisplay -workspace 3 output $leftdisplay -workspace 4 output $leftdisplay -workspace 5 output $leftdisplay -workspace 6 output $leftdisplay -workspace 7 output $leftdisplay -workspace 8 output $leftdisplay -workspace 9 output $leftdisplay -workspace 10 output $leftdisplay - -workspace 11 output $rightdisplay -workspace 12 output $rightdisplay -workspace 13 output $rightdisplay -workspace 14 output $rightdisplay -workspace 15 output $rightdisplay -workspace 16 output $rightdisplay -workspace 17 output $rightdisplay -workspace 18 output $rightdisplay -workspace 19 output $rightdisplay -workspace 20 output $rightdisplay - -# Allow dragging of floating windows whilst holding $mod -floating_modifier $mod - -# Resize mode -mode "resize" { - bindsym Left resize shrink width 10 px or 1 ppt - bindsym Down resize grow height 10 px or 1 ppt - bindsym Up resize shrink height 10 px or 1 ppt - bindsym f resize grow width 10 px or 1 ppt - - # Exit resize mode - bindsym Return mode "default" - bindsym Escape mode "default" - bindsym $mod+r mode "default" -} - -bindsym $mod+r mode "resize" - - -bindsym { -# Move windows -$mod+Shift+b move left -$mod+Shift+f move right -$mod+Shift+p move up -$mod+Shift+n move down - -$mod+Shift+Left move left -$mod+Shift+Right move right -$mod+Shift+Up move up -$mod+Shift+Down move down - -# Shift focus -$mod+b focus left -$mod+f focus right -$mod+p focus up -$mod+n focus down -$mod+a focus parent - -# Splits -$mod+h split h -$mod+v split v - -# Fullscreen -$mod+$alt+f fullscreen toggle - -# Floating -$mod+Shift+space floating toggle -$mod+space focus mode_toggle - -# Close window -$mod+Shift+q kill - -# Change window arrangement -$mod+e layout toggle split -$mod+t layout tabbed -$mod+s layout stacking -} - -### ### -# Appearance # -### ### - -default_border pixel 1 - -# Colors -set $blue #5E81AC -set $orange #D08770 -set $grey #2E3440 -set $wallpaper #242933 - -set $primary '#815986' -set $background '#2d272f' -set $wallpaper '#242933' - -client.focused $primary $background $primary $primary $primary -client.focused_inactive $primary $background $primary $background $background -client.unfocused $background $background $primary $background $background - -# client.focused $blue $grey $blue $blue $blue -# client.focused_inactive $grey $grey $blue $blue $grey -# client.unfocused $grey $grey $blue $blue $grey -# client.urgent $orange $wallpaper $orange $orange $orange - -# Gaps -gaps inner 10 - -# Themes - -set $gnome-schema org.gnome.desktop.interface - -exec_always { - gsettings set $gnome-schema gtk-theme 'Nordic-darker' - gsettings set $gnome-schema icon-theme 'ePapirus-Dark' - gsettings set $gnome-schema font-name 'Source Sans Pro:12' - gsettings set $gnome-schema text-scaling-factor 1 -} - -### ### -# Desktop Features # -### ### - -# This section includes basic desktop features, such as -# the ability to launch programs and functional media keys - -# Sensible launcher (launches program based on workspace) -bindsym $mod+Return exec i3-sensible-launcher - -# Terminal launch override -bindsym $mod+Shift+Return exec alacritty - -# Program menu -bindsym $mod+d exec wofi --show drun - -# Media keys -bindsym --locked { - XF86AudioPlay exec playerctl play-pause - XF86AudioNext exec playerctl next - XF86AudioPrev exec playerctl previous -} - -# Volume keys -bindsym --locked { - XF86AudioRaiseVolume exec pactl set-sink-volume @DEFAULT_SINK@ +1% - XF86AudioLowerVolume exec pactl set-sink-volume @DEFAULT_SINK@ -1% - XF86AudioMute exec pactl set-sink-mute @DEFAULT_SINK@ toggle -} -# Backlight -bindsym --locked { - XF86MonBrightnessUp exec light -A 5 - XF86MonBrightnessDown exec light -U 5 -} - -# Lock screen -bindsym $mod+l exec loginctl lock-session - -# Notification management -bindsym $mod+Ctrl+Space exec dunstctl close - -# Screenshot bindings -bindsym { - Shift+Print exec grimshot copy area - Ctrl+Print exec grimshot copy window - Print exec grimshot copy screen - Mod1+Print exec grimshot copy output -} - -# Start daemons -#include /etc/sway/config.d/50-systemd-user.conf -exec env XDG_CURRENT_DESKTOP=sway systemctl --user import-environment DISPLAY WAYLAND_DISPLAY SWAYSOCK XDG_CURRENT_DESKTOP PATH -exec env XDG_CURRENT_DESKTOP=sway hash dbus-update-activation-environment 2>/dev/null && \ - env XDG_CURRENT_DESKTOP=sway dbus-update-activation-environment --systemd DISPLAY WAYLAND_DISPLAY SWAYSOCK XDG_CURRENT_DESKTOP PATH -exec_always /usr/bin/systemctl --user start sway-session.target - -# Start status bars -exec eww open-many leftbar rightbar - -# Keyboard settings -input * { - xkb_numlock enabled - xkb_options compose:caps - xkb_file ~/.config/sway/keymap.xkb -} - -input type:touchpad { - tap enabled -} diff --git a/.config/sway/display-arrangement.conf##hostname.normandy b/.config/sway/display-arrangement.conf##hostname.normandy index 9533ff1..88871ec 100644 --- a/.config/sway/display-arrangement.conf##hostname.normandy +++ b/.config/sway/display-arrangement.conf##hostname.normandy @@ -3,9 +3,9 @@ ### ### set $leftdisplay 'HDMI-A-1' -set $centerdisplay 'DP-2' +set $rightdisplay 'DP-2' output { $leftdisplay pos 0 0 mode --custom 1920x1080@75Hz - $centerdisplay pos 1920 0 mode --custom 1920x1080@75Hz + $rightdisplay pos 1920 0 mode --custom 1920x1080@75Hz } diff --git a/.config/sway/input.conf##default b/.config/sway/input.conf##default new file mode 100644 index 0000000..009d0ac --- /dev/null +++ b/.config/sway/input.conf##default @@ -0,0 +1,21 @@ +## Keyboard Settings +input type:keyboard { + xkb_numlock enabled + xkb_options compose:caps + xkb_file ~/.config/sway/keymap.xkb +} + +## Touchpad Settings +input type:touchpad { + tap enabled + natural_scroll enabled + dwt disabled + drag enabled + accel_profile adaptive +} + +## Mouse Settings +input type:pointer { + accel_profile flat + natural_scroll disabled +} diff --git a/.config/sway/input.conf##hostname.normandy b/.config/sway/input.conf##hostname.normandy new file mode 100644 index 0000000..5af755e --- /dev/null +++ b/.config/sway/input.conf##hostname.normandy @@ -0,0 +1,21 @@ +## Keyboard Settings +input type:keyboard { + xkb_numlock enabled + xkb_options compose:menu + xkb_file ~/.config/sway/keymap.xkb +} + +## Touchpad Settings +input type:touchpad { + tap enabled + natural_scroll enabled + dwt disabled + drag enabled + accel_profile adaptive +} + +## Mouse Settings +input type:pointer { + accel_profile flat + natural_scroll disabled +} diff --git a/.config/sway/workspaces.json##hostname.normandy b/.config/sway/workspaces.json##hostname.normandy index 70a95ab..1efd816 100644 --- a/.config/sway/workspaces.json##hostname.normandy +++ b/.config/sway/workspaces.json##hostname.normandy @@ -2,44 +2,9 @@ "personal": { "left": [ { - "index": 1, - "name": "terminal", - "exec": "alacritty" - }, - { - "index": 2, - "name": "code", - "exec": "alacritty" - }, - { - "index": 3, - "name": "internet", - "exec": "firefox --new-window" - }, - { - "index": 4, - "name": "project", - "exec": "firefox --new-window" - }, - { - "index": 5, - "name": "VM management", - "exec": "virt-manager" - }, - { - "index": 6, - "name": "documents", - "exec": "alacritty" - }, - { - "index": 7, - "name": "music", - "exec": "feishin" - }, - { - "index": 8, - "name": "discord", - "exec": "discord" + "index": 10, + "name": "config", + "exec": "pavucontrol" }, { "index": 9, @@ -47,9 +12,46 @@ "exec": "alacritty" }, { - "index": 10, - "name": "config", - "exec": "pavucontrol" + "index": 8, + "name": "discord", + "exec": "discord" + }, + { + "index": 7, + "name": "music", + "exec": "feishin" + }, + { + "index": 6, + "name": "documents", + "exec": "alacritty" + }, + { + "index": 5, + "name": "VM management", + "exec": "virt-manager" + }, + { + "index": 4, + "name": "project", + "exec": "env MOZ_ENABLE_WAYLAND=0 firefox --new-window", + "program_name": "firefox" + }, + { + "index": 3, + "name": "internet", + "exec": "env MOZ_ENABLE_WAYLAND=0 firefox --new-window", + "program_name": "firefox" + }, + { + "index": 2, + "name": "code", + "exec": "alacritty" + }, + { + "index": 1, + "name": "terminal", + "exec": "alacritty" } ], "right": [ @@ -66,7 +68,8 @@ { "index": 13, "name": "internet", - "exec": "firefox --new-window" + "exec": "env MOZ_ENABLE_WAYLAND=0 firefox --new-window", + "program_name": "firefox" }, { "index": 14,