K2LL33D SHELL

 Apache/2.4.7 (Ubuntu)
 Linux sman1baleendah 3.13.0-24-generic #46-Ubuntu SMP Thu Apr 10 19:11:08 UTC 2014 x86_64
 uid=33(www-data) gid=33(www-data) groups=33(www-data)
 safemode : OFF
 MySQL: ON | Perl: ON | cURL: OFF | WGet: ON
  >  / usr / share / bash-completion / completions /
server ip : 172.67.156.115

your ip : 172.70.179.91

H O M E


Filename/usr/share/bash-completion/completions/quotaoff
Size3.67 kb
Permissionrw-r--r--
Ownerroot : root
Create time27-Apr-2025 09:54
Last modified07-Apr-2014 22:10
Last accessed05-Jul-2025 14:22
Actionsedit | rename | delete | download (gzip)
Viewtext | code | image
# bash completion for quota-tools -*- shell-script -*-

_user_or_group()
{
local i

# complete on groups if -g was given
for (( i=1; i < cword; i++ )); do
if [[ "${words[i]}" == -@(g|-group) ]]; then
COMPREPLY=( $( compgen -g -- "$cur" ) )
return 0
fi
done

# otherwise complete on users
COMPREPLY=( $( compgen -u -- "$cur" ) )
}

_quota_parse_help()
{
local opts=$( _parse_help "$1" )
[[ $opts ]] || opts=$( _parse_usage "$1" ) # non-GNU?
COMPREPLY=( $( compgen -W "$opts" -- "$cur" ) )
[[ $COMPREPLY == *= ]] && compopt -o nospace
}

_quota_formats()
{
COMPREPLY=( $( compgen -W 'vfsold vfsv0 rpc xfs' -- "$cur" ) )
}

_filesystems()
{
# Only list filesystems starting with "/", otherwise we also get
#+ "binfmt_misc", "proc", "tmpfs", ...
COMPREPLY=( $( compgen -W "$(awk '/^\// {print $1}' /etc/mtab)" \
-- "$cur" ) )
}

_quota()
{
local cur prev words cword split
_init_completion -s || return

case $prev in
-F|--format)
_quota_formats
return 0
;;
-h|--help|-V|--version)
return 0
;;
esac

$split && return 0

if [[ "$cur" == -* ]]; then
_quota_parse_help "$1"
else
_user_or_group
fi
} &&
complete -F _quota -o default quota

_setquota()
{
local cur prev words cword split
_init_completion -s || return

case $prev in
-F|--format)
_quota_formats
return 0
;;
-p|--prototype)
_user_or_group
return 0
;;
-h|--help|-V|--version)
return 0
;;
esac

$split && return 0

if [[ "$cur" == -* ]]; then
_quota_parse_help "$1"
else
local args
_count_args

case $args in
1)
_user_or_group
;;
2)
_filesystems
;;
esac

fi
} &&
complete -F _setquota -o default setquota

_edquota()
{
local cur prev words cword split
_init_completion -s || return

case $prev in
-F|--format)
_quota_formats
return 0
;;
-f|--filesystem)
_filesystems
return 0
;;
-p|--prototype)
_user_or_group
return 0
;;
-h|--help|-V|--version)
return 0
;;
esac

$split && return 0

if [[ "$cur" == -* ]]; then
_quota_parse_help "$1"
else
_user_or_group
fi
} &&
complete -F _edquota -o default edquota

_quotacheck()
{
local cur prev words cword split
_init_completion -s || return

case $prev in
-F|--format)
_quota_formats
return 0
;;
-h|--help|-V|--version)
return 0
;;
esac

$split && return 0

if [[ "$cur" == -* ]]; then
_quota_parse_help "$1"
else
_filesystems
fi
} &&
complete -F _quotacheck -o default quotacheck repquota

_quotaon()
{
local cur prev words cword split
_init_completion -s || return

case $prev in
-F|--format)
_quota_formats
return 0
;;
-x|--xfs-command)
COMPREPLY=( $( compgen -W 'delete enforce' -- "$cur" ) )
return 0
;;
-h|--help|-V|--version)
return 0
;;
esac

$split && return 0

if [[ "$cur" == -* ]]; then
_quota_parse_help "$1"
else
_filesystems
fi
} &&
complete -F _quotaon -o default quotaon quotaoff

# ex: ts=4 sw=4 et filetype=sh