summaryrefslogtreecommitdiff
path: root/.config/screenlayout
diff options
context:
space:
mode:
authorBenjamin Chausse <benjamin@chausse.xyz>2024-01-13 17:33:24 -0500
committerBenjamin Chausse <benjamin@chausse.xyz>2024-01-13 17:33:24 -0500
commitd3d4381b296912577550ae1d0310dbc35f7f98cd (patch)
treea3268f3474f6af6a7a15ef6a763972e89805a96a /.config/screenlayout
parent7838c38253bb1a311c8fa96848802402fbf6b9eb (diff)
sxhkd housekeeping and debloat
Diffstat (limited to '.config/screenlayout')
-rwxr-xr-x.config/screenlayout/quick-presentation20
-rwxr-xr-x.config/screenlayout/workstation-dualmon3
-rwxr-xr-x.config/screenlayout/workstation-singlemon3
3 files changed, 26 insertions, 0 deletions
diff --git a/.config/screenlayout/quick-presentation b/.config/screenlayout/quick-presentation
new file mode 100755
index 0000000..8a8123b
--- /dev/null
+++ b/.config/screenlayout/quick-presentation
@@ -0,0 +1,20 @@
+#!/bin/sh
+
+mainmon="eDP"
+
+# List monitors with xrandr
+# Keep all linues that contain " connected"
+# Remove the main monitor from the list
+# Remove all disconnected monitors
+# Delete empty lines
+# Get the first non-main monitor
+# Sanitize the output (keep only the monitor name)
+othermon="$(xrandr | grep " connected" |
+ sed "s/.*$mainmon\s.*//g;
+ /^$/d;
+ s/\([A-Z0-9]\+\) .*/\1/g" |
+ head -n 1)"
+
+xrandr --output "$mainmon" --auto --output "$othermon" --auto --above "$mainmon"
+
+makewall
diff --git a/.config/screenlayout/workstation-dualmon b/.config/screenlayout/workstation-dualmon
new file mode 100755
index 0000000..08c080f
--- /dev/null
+++ b/.config/screenlayout/workstation-dualmon
@@ -0,0 +1,3 @@
+#!/bin/sh
+xrandr --output eDP --primary --mode 2256x1504 --pos 2560x0 --rotate normal --output DisplayPort-0 --off --output DisplayPort-1 --off --output DisplayPort-2 --mode 2560x1080 --pos 0x0 --rotate inverted --output DisplayPort-3 --off --output DisplayPort-4 --off --output DisplayPort-5 --off --output DisplayPort-6 --off --output DisplayPort-7 --off
+makewall
diff --git a/.config/screenlayout/workstation-singlemon b/.config/screenlayout/workstation-singlemon
new file mode 100755
index 0000000..e75dd9a
--- /dev/null
+++ b/.config/screenlayout/workstation-singlemon
@@ -0,0 +1,3 @@
+#!/bin/sh
+xrandr --output eDP --primary --mode 2256x1504 --pos 0x0 --rotate normal --output DisplayPort-0 --off --output DisplayPort-1 --off --output DisplayPort-2 --off --output DisplayPort-3 --off --output DisplayPort-4 --off --output DisplayPort-5 --off --output DisplayPort-6 --off --output DisplayPort-7 --off
+makewall