From feaeb4471fa0daf0f2d8a8f4cfbd4cc3557f0127 Mon Sep 17 00:00:00 2001 From: Micke Nordin Date: Sun, 12 Nov 2023 14:09:39 +0000 Subject: [PATCH] Add monitor --- templates/sway_config.j2 | 61 ++++++++-------------------------------- 1 file changed, 12 insertions(+), 49 deletions(-) diff --git a/templates/sway_config.j2 b/templates/sway_config.j2 index 8253bdf..ca75731 100644 --- a/templates/sway_config.j2 +++ b/templates/sway_config.j2 @@ -1,11 +1,5 @@ -# Default config for sway -# -# Copy this to ~/.config/sway/config and edit it to your liking. -# # Read `man 5 sway` for a complete reference. -### Variables -# # Logo key. Use Mod1 for Alt. set $mod Mod4 # Home row direction keys, like vim @@ -19,6 +13,8 @@ set $term foot # Note: pass the final command to swaymsg so that the resulting window can be opened # on the original workspace that the command was run on. set $menu wofi -S drun | xargs swaymsg exec -- + +# Autostart exec --no-startup-id nm-applet exec --no-startup-id autotiling exec --no-startup-id lxpolkit @@ -28,17 +24,14 @@ exec --no-startup-id fcitx5 include /etc/sway/config-vars.d/* ### Output configuration -# # Default wallpaper (more resolutions are available in /usr/share/backgrounds/sway/) output * bg {{ wallpaper_path }} fill -# -# Example configuration: -# -# output HDMI-A-1 resolution 1920x1080 position 1920,0 -# output eDP-1 resolution 1920x1080 position 2560,0 -# output DP-1 resolution 2560x1440 position 0,0 -output eDP-1 resolution 1920x1080 position 3440,0 +# Big curved monitor at home output DP-1 resolution 3440x1440 position 0,0 +# Smol flat monitor at home +output HDMI-A-1 resolution 1920x1080 position 3440,460 +# Laptop screen +output eDP-1 resolution 1920x1080 position 3440,0 # You can get the names of your outputs by running: swaymsg -t get_outputs # Gaps smart_gaps on @@ -46,9 +39,6 @@ gaps inner 3 gaps outer 2 ### Idle configuration -# -# Example configuration: -# set $lock 'swaylock -f -c 000000' exec swayidle -w \ timeout 300 $lock \ @@ -59,17 +49,6 @@ exec swayidle -w \ # your displays after another 300 seconds, and turn your screens back on when # resumed. It will also lock your screen before your computer goes to sleep. -### Input configuration -# -# Example configuration: -# -# input "2:14:SynPS/2_Synaptics_TouchPad" { -# dwt enabled -# tap enabled -# natural_scroll enabled -# middle_emulation enabled -# } -# # You can get the names of your inputs by running: swaymsg -t get_inputs # Read `man 5 sway-input` for more information about this section. input type:keyboard { @@ -78,9 +57,7 @@ input type:keyboard { xkb_options caps:escape } ### Key bindings -# # Basics: -# # Start a terminal bindsym $mod+Return exec $term @@ -102,9 +79,8 @@ input type:keyboard { # Exit sway (logs you out of your Wayland session) bindsym $mod+Shift+e exec swaynag -t warning -m 'You pressed the exit shortcut. Do you really want to exit sway? This will end your Wayland session.' -B 'Yes, exit sway' 'swaymsg exit' -# + # Moving around: -# # Move your focus around bindsym $mod+$left focus left bindsym $mod+$down focus down @@ -126,9 +102,8 @@ input type:keyboard { bindsym $mod+Shift+Down move down bindsym $mod+Shift+Up move up bindsym $mod+Shift+Right move right -# + # Workspaces: -# # Switch to workspace bindsym $mod+1 workspace number 1 bindsym $mod+2 workspace number 2 @@ -163,9 +138,8 @@ input type:keyboard { bindsym Mod1+Shift+z move container to workspace zoom # Note: workspaces can have any name you want, not just numbers. # We just use 1-10 as the default. -# + # Layout stuff: -# # You can "split" the current object of your focus with # $mod+b or $mod+v, for horizontal and vertical splits # respectively. @@ -188,9 +162,8 @@ input type:keyboard { # Move focus to the parent container bindsym $mod+a focus parent -# + # Scratchpad: -# # Sway has a "scratchpad", which is a bag of holding for windows. # You can send windows there and get them back later. @@ -246,12 +219,6 @@ exec dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DE bindsym $mod+Shift+s mode $screenshot_mode mode $screenshot_mode { - # Screenshots: - # Super+P: Current window - # Super+Shift+p: Select area - # Super+Alt+p Current output - # Super+Ctrl+p Select a window - bindsym s exec grimshot save active bindsym a exec grimshot save area bindsym o exec grimshot save output @@ -259,16 +226,12 @@ mode $screenshot_mode { bindsym Return mode "default" bindsym Escape mode "default" } -# + # Status Bar: -# # Read `man 5 sway-bar` for more information about this section. bar { position top - # When the status_command prints a new line to stdout, swaybar updates. - # The default just shows the current date and time. - #status_command while date +'%Y-%m-%d %H:%M:%S'; do sleep 1; done swaybar_command waybar colors {