mirror of
git://git.code.sf.net/p/zsh/code
synced 2025-09-03 10:21:46 +02:00
22054: completion for fusermount.
This commit is contained in:
parent
a5f418d5f1
commit
fa84d603d1
2 changed files with 29 additions and 0 deletions
|
@ -1,3 +1,8 @@
|
|||
2005-12-07 Clint Adams <clint@zsh.org>
|
||||
|
||||
* 22054: Completion/Linux/Command/_fusermount:
|
||||
completion for fusermount.
|
||||
|
||||
2005-12-06 Peter Stephenson <pws@csr.com>
|
||||
|
||||
* 22053: Etc/FAQ.yo, Functions/Newuser/zsh-newuser-install:
|
||||
|
|
24
Completion/Linux/Command/_fusermount
Normal file
24
Completion/Linux/Command/_fusermount
Normal file
|
@ -0,0 +1,24 @@
|
|||
#compdef fusermount
|
||||
|
||||
local expl context state line
|
||||
typeset -A opt_args
|
||||
|
||||
_arguments \
|
||||
'-h[help]' \
|
||||
'-v[version]' \
|
||||
'-o[options]:mount options:_values -s , "mount options" default_permissions allow_other allow_root kernel_cache large_read direct_io max_read=:size: hard_remove debug fsname=:name: use_ino readdir_ino nonempty umask=:umask: uid=:uid: gid=:gid:' \
|
||||
'-u[unmount]' \
|
||||
'-q[quiet]' \
|
||||
'-z[lazy unmount]' \
|
||||
':mountpoint:->mountpoint' && return 0
|
||||
|
||||
case "$state" in
|
||||
(mountpoint)
|
||||
if [[ $+opt_args[-u] -eq 0 ]]; then
|
||||
_files -/
|
||||
else
|
||||
_wanted mounted expl 'mounted filesystem' \
|
||||
compadd ${${${"${(f)$(< /etc/mtab)}"}#* }%% *}
|
||||
fi
|
||||
;;
|
||||
esac
|
Loading…
Reference in a new issue