From 34baf7e029264c201df3ed5d9d57e1e9ad3a901d Mon Sep 17 00:00:00 2001 From: fabian Date: Thu, 18 Jan 2024 15:50:34 +0100 Subject: [PATCH] simplified finding the home dir --- scripts/mount_general.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/scripts/mount_general.sh b/scripts/mount_general.sh index 8519483..1a16264 100644 --- a/scripts/mount_general.sh +++ b/scripts/mount_general.sh @@ -2,13 +2,12 @@ set -euo pipefail sshMount () { - clientUser=$(whoami); serverUser=$1; serverHost=$2; shift 2; args=($@) for ((i=0; i < ${#args[@]}; i=i + 2)); do - sshfs ${serverUser}@${serverHost}:/citadel/${args[$i]}/ /home/${clientUser}/${args[$i + 1]}/ -o reconnect,ServerAliveInterval=15,ServerAliveCountMax=8 + sshfs ${serverUser}@${serverHost}:/citadel/${args[$i]}/ $HOME/${args[$i + 1]}/ -o reconnect,ServerAliveInterval=15,ServerAliveCountMax=8 done }