about summary refs log tree commit diff
path: root/dwmc
diff options
context:
space:
mode:
authorYour Name <you@example.com>2020-10-21 20:03:55 +0100
committerYour Name <you@example.com>2020-10-21 20:03:55 +0100
commit61fb8628182db20d974eb63cedf41dceb7abf14c (patch)
tree583539acf5622edc8f642bf881dd181f14b89ba3 /dwmc
parentRemove scripts (diff)
downloaddwm-61fb8628182db20d974eb63cedf41dceb7abf14c.tar.gz
dwm-61fb8628182db20d974eb63cedf41dceb7abf14c.tar.bz2
dwm-61fb8628182db20d974eb63cedf41dceb7abf14c.zip
Removed keyhandling functionality
Diffstat (limited to 'dwmc')
-rwxr-xr-xdwmc40
1 files changed, 40 insertions, 0 deletions
diff --git a/dwmc b/dwmc
new file mode 100755
index 0000000..9deaec6
--- /dev/null
+++ b/dwmc
@@ -0,0 +1,40 @@
+#!/usr/bin/env sh
+
+signal() {
+	xsetroot -name "dsignal:$*"
+}
+
+case $# in
+1)
+	case $1 in
+	setlayout | view | viewall | tagall | togglebar | togglefloating | togglefullscreen | zoom | killclient | quit)
+		signal $1
+		;;
+	*)
+		echo "Unknown command or missing one argument."
+		exit 1
+		;;
+	esac
+	;;
+2)
+	case $1 in
+	view)
+        signal $1 ui $(expr $2 - 1)
+		;;
+	viewex | toggleviewex | tagex | toggletagex | setlayoutex | focusstack | movestack | cyclelayout | incnmaster | focusmon | tagmon)
+        signal $1 i $2
+		;;
+	setmfact)
+		signal $1 f $2
+		;;
+	*)
+		echo "Unknown command or one too many arguments."
+		exit 1
+		;;
+	esac
+	;;
+*)
+	echo "Too many arguments."
+	exit 1
+	;;
+esac