summaryrefslogtreecommitdiff
path: root/support/lsh.sh
diff options
context:
space:
mode:
authorWayne Davison <wayne@opencoder.net>2020-06-04 12:37:07 -0700
committerWayne Davison <wayne@opencoder.net>2020-06-04 12:58:02 -0700
commit55290c858425873a6bf2be7bc841dbb68c023767 (patch)
tree47ca07954c3e70e0684567da07d2a7fbdeb9a420 /support/lsh.sh
parente633091d23ee483f4bc7a0f8bca15b5b17958fff (diff)
downloadrsync-55290c858425873a6bf2be7bc841dbb68c023767.tar.gz
Add hostname "lh" as a --no-cd localhost.
Diffstat (limited to 'support/lsh.sh')
-rwxr-xr-xsupport/lsh.sh3
1 files changed, 2 insertions, 1 deletions
diff --git a/support/lsh.sh b/support/lsh.sh
index b63444e3..f74a8ef4 100755
--- a/support/lsh.sh
+++ b/support/lsh.sh
@@ -7,7 +7,7 @@
# command.
user=''
-do_cd=y # Default path is user's home dir, just like ssh.
+do_cd=y # Default path is user's home dir (just like ssh) unless host is "lh".
while : ; do
case "$1" in
@@ -16,6 +16,7 @@ while : ; do
--no-cd) do_cd=n; shift ;;
-*) shift ;;
localhost) shift; break ;;
+ lh) do_cd=n; shift; break ;;
*) echo "lsh: unable to connect to host $1" 1>&2; exit 1 ;;
esac
done