summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorxengineering <me@xengineering.eu>2022-01-07 13:26:10 +0100
committerxengineering <me@xengineering.eu>2022-01-07 13:26:10 +0100
commit0567545d086f933bea2e662e54ca29de7a670236 (patch)
treee5712f0aa3e95a84559fe44a15588a2cf64b4ff9
parent2a8fad56cae1a579c42ab1b24bf24556f9fc36c3 (diff)
downloaddotfiles-0567545d086f933bea2e662e54ca29de7a670236.tar
dotfiles-0567545d086f933bea2e662e54ca29de7a670236.tar.zst
dotfiles-0567545d086f933bea2e662e54ca29de7a670236.zip
Sway: Modular Approach for different Monitor Setups
-rw-r--r--.config/sway/config19
l---------.config/sway/setup1
-rw-r--r--.config/sway/setups/home16
-rw-r--r--.config/sway/setups/home_single14
4 files changed, 33 insertions, 17 deletions
diff --git a/.config/sway/config b/.config/sway/config
index b788577..87894bc 100644
--- a/.config/sway/config
+++ b/.config/sway/config
@@ -22,24 +22,9 @@ set $menu bemenu-run -p ">>>" | xargs swaymsg exec
#
# Default wallpaper (more resolutions are available in /usr/share/backgrounds/sway/)
output * bg ~/wallpaper fill
-#
-# Example configuration:
-#
-# output HDMI-A-1 resolution 1920x1080 position 1920,0
-#
-# You can get the names of your outputs by running: swaymsg -t get_outputs
-
-# left monitor
-output HDMI-A-2 resolution 1920x1080 position 0,0
-workspace 1 output HDMI-A-2
-
-# right monitor
-output DP-1 resolution 1920x1080 position 1920,0
-workspace 2 output DP-1
-# lower monitor
-output eDP-1 resolution 1920x1080 position 0,1080
-workspace 3 output eDP-1
+# include current output/monitor setup
+include ~/.config/sway/setup
### Idle configuration
diff --git a/.config/sway/setup b/.config/sway/setup
new file mode 120000
index 0000000..3652e6a
--- /dev/null
+++ b/.config/sway/setup
@@ -0,0 +1 @@
+setups/home_single \ No newline at end of file
diff --git a/.config/sway/setups/home b/.config/sway/setups/home
new file mode 100644
index 0000000..c5dd9a2
--- /dev/null
+++ b/.config/sway/setups/home
@@ -0,0 +1,16 @@
+
+# The Monitor Setup I use at Home (three monitors in total)
+
+# Use `swaymsg -t get_outputs` to list monitors
+
+# left monitor
+output HDMI-A-2 resolution 1920x1080 position 0,0
+workspace 1 output HDMI-A-2
+
+# right monitor
+output DP-1 resolution 1920x1080 position 1920,0
+workspace 2 output DP-1
+
+# lower monitor
+output eDP-1 resolution 1920x1080 position 0,1080
+workspace 3 output eDP-1
diff --git a/.config/sway/setups/home_single b/.config/sway/setups/home_single
new file mode 100644
index 0000000..1613df7
--- /dev/null
+++ b/.config/sway/setups/home_single
@@ -0,0 +1,14 @@
+
+# The Monitor Setup I use at Home (only one monitor)
+
+# Use `swaymsg -t get_outputs` to list monitors
+
+# left monitor
+output HDMI-A-2 resolution 1920x1080 position 0,0
+workspace 1 output HDMI-A-2
+
+# right monitor
+output DP-1 disable
+
+# lower monitor
+output eDP-1 disable