#!/bin/bash set -e for i in "$@"; do mnt=~/mnt/$i if ! mountpoint -q $mnt; then mkdir -p $mnt sshfs -o reconnect,kernel_cache web-$i@karif: $mnt else fusermount -u $mnt rmdir $mnt fi done