summaryrefslogtreecommitdiff
path: root/archive/scripts/desktop/dmenu_ssh
diff options
context:
space:
mode:
Diffstat (limited to 'archive/scripts/desktop/dmenu_ssh')
-rwxr-xr-xarchive/scripts/desktop/dmenu_ssh7
1 files changed, 7 insertions, 0 deletions
diff --git a/archive/scripts/desktop/dmenu_ssh b/archive/scripts/desktop/dmenu_ssh
new file mode 100755
index 00000000..76d9aa72
--- /dev/null
+++ b/archive/scripts/desktop/dmenu_ssh
@@ -0,0 +1,7 @@
+#!/bin/sh
+
+host=$(perl -wlne'/^Host\s+(\S+)/ and !/\*/ and print $1' $HOME/.ssh/config \
+ | dmenu -p "ssh to tmux on host" "$@")
+if [ -n "$host" ]; then
+ xfce4-terminal -x ssh-and-tmux "$host"
+fi