summaryrefslogtreecommitdiff
path: root/desktop/spectrwm/examples/spectrwm_screenshot.sh
diff options
context:
space:
mode:
Diffstat (limited to 'desktop/spectrwm/examples/spectrwm_screenshot.sh')
-rw-r--r--desktop/spectrwm/examples/spectrwm_screenshot.sh21
1 files changed, 21 insertions, 0 deletions
diff --git a/desktop/spectrwm/examples/spectrwm_screenshot.sh b/desktop/spectrwm/examples/spectrwm_screenshot.sh
new file mode 100644
index 0000000000..6a01fd67a6
--- /dev/null
+++ b/desktop/spectrwm/examples/spectrwm_screenshot.sh
@@ -0,0 +1,21 @@
+#!/bin/sh
+
+
+SCROT=$(which scrot)
+[ -x "${SCROT}" ] || exit 1
+
+screenshot() {
+ case $1 in
+ full)
+ "${SCROT}" --multidisp
+ ;;
+ window)
+ sleep 0.5
+ "${SCROT}" --select
+ ;;
+ *)
+ ;;
+ esac;
+}
+
+screenshot $1