summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortsxv478 <atvx717@infraredcombat.xyz>2025-01-18 00:29:18 +0300
committertsxv478 <atvx717@infraredcombat.xyz>2025-01-18 00:29:18 +0300
commit98bac79a5878faff965728ad668c65da8a3c56e1 (patch)
treeed6cec6df512d72419b7b9a36bbe02be38628fc9
parent24f6c0907c0574df5bd083220a560332387af8fb (diff)
sshmenu: check if dmenu is installedHEADmaster
-rwxr-xr-xsshmenu2
1 files changed, 1 insertions, 1 deletions
diff --git a/sshmenu b/sshmenu
index 8bec492..115a111 100755
--- a/sshmenu
+++ b/sshmenu
@@ -1,6 +1,6 @@
#!/bin/sh
-if [ $DISPLAY ]; then
+if [ $DISPLAY ] && command -v dmenu >/dev/null; then
host=$(grep "^Host" $HOME/.ssh/config | cut -d ' ' -f 2 | dmenu -i -c -l 10 -p "SSH to:")
[ "$host" ] || exit 0