From 228a2d7f84c78c4ab09304b71c7d038bf6b6ffbd Mon Sep 17 00:00:00 2001
From: finga <finga@onders.org>
Date: Thu, 19 Sep 2024 00:19:29 +0200
Subject: [PATCH 1/2] workspaces: Extract workspace config

Extract the configuration for workspaces so it is contained in a
specific file.
---
 .config/sway/config              | 38 --------------------------------
 .config/sway/config.d/workspaces | 37 +++++++++++++++++++++++++++++++
 .gitignore.d/sway                |  1 +
 3 files changed, 38 insertions(+), 38 deletions(-)
 create mode 100644 .config/sway/config.d/workspaces

diff --git a/.config/sway/config b/.config/sway/config
index 10e6c6d..6e9ef16 100644
--- a/.config/sway/config
+++ b/.config/sway/config
@@ -85,44 +85,6 @@ bindsym $mod+Shift+Down move down
 bindsym $mod+Shift+Up move up
 bindsym $mod+Shift+Right move right
 
-#
-# Workspace setup
-#
-set $ws1 "1"
-set $ws2 "2"
-set $ws3 "3"
-set $ws4 "4"
-set $ws5 "5"
-set $ws6 "6"
-set $ws7 "7"
-set $ws8 "8"
-set $ws9 "9"
-set $ws10 "10"
-
-# Switch to workspace
-bindsym $mod+1 workspace number $ws1
-bindsym $mod+2 workspace number $ws2
-bindsym $mod+3 workspace number $ws3
-bindsym $mod+4 workspace number $ws4
-bindsym $mod+5 workspace number $ws5
-bindsym $mod+6 workspace number $ws6
-bindsym $mod+7 workspace number $ws7
-bindsym $mod+8 workspace number $ws8
-bindsym $mod+9 workspace number $ws9
-bindsym $mod+0 workspace number $ws10
-
-# Move focused container to workspace
-bindsym $mod+Shift+1 move container to workspace number $ws1
-bindsym $mod+Shift+2 move container to workspace number $ws2
-bindsym $mod+Shift+3 move container to workspace number $ws3
-bindsym $mod+Shift+4 move container to workspace number $ws4
-bindsym $mod+Shift+5 move container to workspace number $ws5
-bindsym $mod+Shift+6 move container to workspace number $ws6
-bindsym $mod+Shift+7 move container to workspace number $ws7
-bindsym $mod+Shift+8 move container to workspace number $ws8
-bindsym $mod+Shift+9 move container to workspace number $ws9
-bindsym $mod+Shift+0 move container to workspace number $ws10
-
 #
 # Resizing containers:
 #
diff --git a/.config/sway/config.d/workspaces b/.config/sway/config.d/workspaces
new file mode 100644
index 0000000..f631673
--- /dev/null
+++ b/.config/sway/config.d/workspaces
@@ -0,0 +1,37 @@
+#
+# Workspace setup
+#
+set $ws1 "1"
+set $ws2 "2"
+set $ws3 "3"
+set $ws4 "4"
+set $ws5 "5"
+set $ws6 "6"
+set $ws7 "7"
+set $ws8 "8"
+set $ws9 "9"
+set $ws10 "10"
+
+# Switch to workspace
+bindsym $mod+1 workspace number $ws1
+bindsym $mod+2 workspace number $ws2
+bindsym $mod+3 workspace number $ws3
+bindsym $mod+4 workspace number $ws4
+bindsym $mod+5 workspace number $ws5
+bindsym $mod+6 workspace number $ws6
+bindsym $mod+7 workspace number $ws7
+bindsym $mod+8 workspace number $ws8
+bindsym $mod+9 workspace number $ws9
+bindsym $mod+0 workspace number $ws10
+
+# Move focused container to workspace
+bindsym $mod+Shift+1 move container to workspace number $ws1
+bindsym $mod+Shift+2 move container to workspace number $ws2
+bindsym $mod+Shift+3 move container to workspace number $ws3
+bindsym $mod+Shift+4 move container to workspace number $ws4
+bindsym $mod+Shift+5 move container to workspace number $ws5
+bindsym $mod+Shift+6 move container to workspace number $ws6
+bindsym $mod+Shift+7 move container to workspace number $ws7
+bindsym $mod+Shift+8 move container to workspace number $ws8
+bindsym $mod+Shift+9 move container to workspace number $ws9
+bindsym $mod+Shift+0 move container to workspace number $ws10
diff --git a/.gitignore.d/sway b/.gitignore.d/sway
index e0c3f31..af41fb2 100644
--- a/.gitignore.d/sway
+++ b/.gitignore.d/sway
@@ -11,6 +11,7 @@
 !/.config/sway/config.d/dunst
 !/.config/sway/config.d/media
 !/.config/sway/config.d/screenlock
+!/.config/sway/config.d/workspaces
 !/.gitignore.d
 !/.gitignore.d/sway
 !/.local

From e857d100d8575bbeb64fa9126965d9b74c6e9e6b Mon Sep 17 00:00:00 2001
From: finga <finga@onders.org>
Date: Thu, 19 Sep 2024 00:21:45 +0200
Subject: [PATCH 2/2] workspaces: Add 0th, 11th and 12th workspaces

---
 .config/sway/config.d/workspaces | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/.config/sway/config.d/workspaces b/.config/sway/config.d/workspaces
index f631673..4560d67 100644
--- a/.config/sway/config.d/workspaces
+++ b/.config/sway/config.d/workspaces
@@ -1,6 +1,7 @@
 #
 # Workspace setup
 #
+set $ws0 "0"
 set $ws1 "1"
 set $ws2 "2"
 set $ws3 "3"
@@ -11,8 +12,11 @@ set $ws7 "7"
 set $ws8 "8"
 set $ws9 "9"
 set $ws10 "10"
+set $ws11 "11"
+set $ws12 "12"
 
 # Switch to workspace
+bindsym $mod+grave workspace number $ws0
 bindsym $mod+1 workspace number $ws1
 bindsym $mod+2 workspace number $ws2
 bindsym $mod+3 workspace number $ws3
@@ -23,8 +27,11 @@ bindsym $mod+7 workspace number $ws7
 bindsym $mod+8 workspace number $ws8
 bindsym $mod+9 workspace number $ws9
 bindsym $mod+0 workspace number $ws10
+bindsym $mod+minus workspace number $ws11
+bindsym $mod+equal workspace number $ws12
 
 # Move focused container to workspace
+bindsym $mod+Shift+grave move container to workspace number $ws0
 bindsym $mod+Shift+1 move container to workspace number $ws1
 bindsym $mod+Shift+2 move container to workspace number $ws2
 bindsym $mod+Shift+3 move container to workspace number $ws3
@@ -35,3 +42,5 @@ bindsym $mod+Shift+7 move container to workspace number $ws7
 bindsym $mod+Shift+8 move container to workspace number $ws8
 bindsym $mod+Shift+9 move container to workspace number $ws9
 bindsym $mod+Shift+0 move container to workspace number $ws10
+bindsym $mod+Shift+underscore move container to workspace number $ws11
+bindsym $mod+Shift+plus move container to workspace number $ws12