about summary refs log tree commit diff
path: root/Completion/Builtins/_stat
blob: ca7d2900d8d8a6fe44773bc911e6326a7cbbd83f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#compdef stat

local expl ret=1

if [[ "$words[CURRENT-1]" = -[AH] ]]; then
  _arrays
else
  _tags files options || return 1

  while _tags; do
    _requested files && _files && ret=0
    _requested options expl 'inode element' &&
        { ! zstyle -t ":completion${curcontext}:options" prefix-needed ||
          [[ "$PREFIX[1]" = + || ret -eq 1 ]] } &&
        compadd "$expl[@]" - +device +inode +mode +nlink +uid +gid +rdev \
                             +size +atime +mtime +ctime +blksize +block +link
  done
fi