aboutsummaryrefslogtreecommitdiff
path: root/scripts/unsetup-vnc-monitor.sh
diff options
context:
space:
mode:
authorAargh Rai <aargh.rai+git@gmail.com>2026-09-09 11:24:19 +0530
committerAargh Rai <aargh.rai+git@gmail.com>2026-09-09 11:24:19 +0530
commit445ae385cfd93eae2a0402a5ffe20378488dee7e (patch)
tree92fff33bb02598451cb74359c1f61a3b6c1f6c87 /scripts/unsetup-vnc-monitor.sh
parente8950c9645a064b7bb5ba09deb59c60a1e9cf19e (diff)
vnc undo, left hand mode script, new functionality in nvim & attempts to fix some suspend issue
Diffstat (limited to 'scripts/unsetup-vnc-monitor.sh')
-rwxr-xr-xscripts/unsetup-vnc-monitor.sh19
1 files changed, 19 insertions, 0 deletions
diff --git a/scripts/unsetup-vnc-monitor.sh b/scripts/unsetup-vnc-monitor.sh
new file mode 100755
index 0000000..8eaa494
--- /dev/null
+++ b/scripts/unsetup-vnc-monitor.sh
@@ -0,0 +1,19 @@
+#!/usr/bin/env bash
+
+set -euo pipefail
+
+export DISPLAY=:0
+
+# Remove the monitors created by the original script.
+xrandr --delmonitor PHYSICAL 2>/dev/null || true
+xrandr --delmonitor VNC 2>/dev/null || true
+
+# Remove any leftover monitor definitions from previous runs.
+xrandr --delmonitor VNC-0 2>/dev/null || true
+xrandr --delmonitor VNC-1 2>/dev/null || true
+xrandr --delmonitor VNC-2 2>/dev/null || true
+
+# Restore the framebuffer to the physical display's resolution.
+xrandr --fb 1920x1080
+
+xrandr --listmonitors