home *** CD-ROM | disk | FTP | other *** search
/ Clickx 115 / Clickx 115.iso / software / tools / windows / tails-i386-0.16.iso / live / filesystem.squashfs / etc / bash_completion.d / fuse < prev    next >
Encoding:
Text File  |  2010-11-16  |  759 b   |  37 lines

  1. # bash completion for fuse
  2.  
  3. have fusermount &&
  4. _fusermount()
  5. {
  6.     COMPREPLY=()
  7.     local cur prev
  8.     _get_comp_words_by_ref cur prev
  9.  
  10.     case $prev in
  11.         -h|-V|-o)
  12.             return 0
  13.             ;;
  14.         -u)
  15.             COMPREPLY=( $( compgen -W "$( awk \
  16.                 '{ if ($3 ~ /^fuse\./) print $2 }' /etc/mtab 2>/dev/null )" \
  17.                 -- "$cur" ) )
  18.             return 0
  19.             ;;
  20.     esac
  21.  
  22.     if [[ "$cur" == -* ]] ; then
  23.         COMPREPLY=( $( compgen -W '-h -V -o -u -q -z' -- "$cur" ) )
  24.     else
  25.         _filedir -d
  26.     fi
  27. } &&
  28. complete -F _fusermount -o filenames fusermount
  29.  
  30. # Local variables:
  31. # mode: shell-script
  32. # sh-basic-offset: 4
  33. # sh-indent-comment: t
  34. # indent-tabs-mode: nil
  35. # End:
  36. # ex: ts=4 sw=4 et filetype=sh
  37.