sshfs-mapper: Added verbosity option.
git-svn-id: https://websvn.glenux.net/svn/Upoc/sshfs-mapper/trunk@1623 eaee96b3-f302-0410-b096-c6cfd47f7835
This commit is contained in:
parent
0a090db765
commit
73410ea881
1 changed files with 40 additions and 33 deletions
|
@ -32,6 +32,7 @@ do_mount() {
|
|||
local localdir=$2
|
||||
local remoteport=$3
|
||||
|
||||
set -x
|
||||
sshfs \
|
||||
-o allow_root \
|
||||
-o idmap=user \
|
||||
|
@ -46,6 +47,7 @@ do_mount() {
|
|||
-o Port=$remoteport \
|
||||
$remotedir \
|
||||
$localdir
|
||||
set +x
|
||||
|
||||
#-o compression=yes
|
||||
}
|
||||
|
@ -65,6 +67,7 @@ Usage: `basename $0` [options]
|
|||
-a, --all Use all maps.
|
||||
-s, --select <map> Only use specified map.
|
||||
-u, --umount Umount user maps (mount if not specified).
|
||||
-v, --verbose Be verbose.
|
||||
EOF
|
||||
exit 1
|
||||
}
|
||||
|
@ -109,6 +112,7 @@ SSHFS_HOST_PATTERN=" "
|
|||
SSHFS_HOST_LIMIT=0
|
||||
SSHFS_HOST_LIST=0
|
||||
SSHFS_HOST_AUTO=0
|
||||
SSHFS_VERBOSE=0
|
||||
OPTFOUND=0
|
||||
while true
|
||||
do
|
||||
|
@ -118,6 +122,9 @@ do
|
|||
OPTARG=${1:-}
|
||||
#echo "$OPT?"
|
||||
case "$OPT" in
|
||||
--verbose|-v) #be verbose
|
||||
SSHFS_VERBOSE=1
|
||||
;;
|
||||
--all|-a) # mount all
|
||||
SSHFS_HOST_AUTO=1
|
||||
OPTFOUND=1
|
||||
|
|
Loading…
Reference in a new issue