Compare commits

..

No commits in common. "784818b510b70a48eec21f2aa5b1fa251246bfd4" and "937fe0142d2a3c93b6d44ece096c3a4cc68f4b5e" have entirely different histories.

3 changed files with 8 additions and 7 deletions

View File

@ -3,4 +3,6 @@ set -euo pipefail
source /sync/scripts/mount_general.sh source /sync/scripts/mount_general.sh
sshMount edi edi fabian FabisDokumente user=$(whoami)
sshMount edi edi $user FabisDokumente

View File

@ -3,4 +3,6 @@ set -euo pipefail
source /sync/scripts/mount_general.sh source /sync/scripts/mount_general.sh
sshMount fabian garrus fabian FabisDokumente media Filme user=$(whoami)
sshMount fabian garrus $user FabisDokumente media Filme

View File

@ -2,13 +2,10 @@
set -euo pipefail set -euo pipefail
sshMount () { sshMount () {
clientUser=$(whoami);
serverUser=$1;
serverHost=$2;
shift 2;
args=($@) args=($@)
args=(${args[@]:2})
for ((i=0; i < ${#args[@]}; i=i + 2)); do 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 $1@$2:/citadel/${args[$i]}/ /home/fabian/${args[$i + 1]}/ -o reconnect,ServerAliveInterval=15,ServerAliveCountMax=8
done done
} }