HEX
Server: nginx/1.28.1
System: Linux 10-41-63-61 6.8.0-31-generic #31-Ubuntu SMP PREEMPT_DYNAMIC Sat Apr 20 00:40:06 UTC 2024 x86_64
User: www (1001)
PHP: 7.4.33
Disabled: passthru,exec,system,putenv,chroot,chgrp,chown,shell_exec,popen,proc_open,pcntl_exec,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,imap_open,apache_setenv
Upload Files
File: //usr/share/zsh/site-functions/_udisks2
#compdef udisksctl

# Completion function for zsh

local curcontext="$curcontext" cmd="$words[1]" params ca_opts
local -i i ret=1
local -a state state_descr line expl cmds opts vals

if (( CURRENT == 2 )); then
  cmds=( $(_call_program commands $cmd complete "$cmd" ${#cmd}) )
  _wanted commands expl "command" compadd -M "r:|-=* r:|=*" -a cmds
else
  curcontext="${curcontext%:*}-${words[2]}:"
  opts=( $(_call_program options $cmd complete "${(q)words[1,2]}" ${(c)#words[1,2]}) )
  for ((i=$#opts;i;i--)); do
    case $opts[i] in
      --block-device)
        opts[i]=( '(-b --block-device -d --drive -p --object-path)'{-b,--block-device=}'[specify block device]:block device:->block-devices' )
      ;;
      --drive)
        opts[i]=( '(-d --drive -b --block-device -p --object-path)'{-d,--drive=}'[specify drive]:drive:->drives' )
      ;;
      --force)
        opts[i]=( '(-f --force)'{-f,--force} )
      ;;
      --file)
        opts[i]=( '(-f --file)'{-f,--file=}'[specify filename]:file:_files' )
      ;;
      --filesystem-type)
        opts[i]=( '(-t --filesystem-type)'{-t,--filesystem-type=}'[specify filesystem type to use]: :_file_systems' )
      ;;
      --no-user-interaction)
        opts[i]=( "--no-user-interaction[don't authenticate the user if needed]" )
      ;;
      --offset)
        opts[i]=( '(-o --offset)'{-o,--offset}'[specify offset]:offset (bytes)' )
      ;;
      --object-path)
        opts[i]=( '(-p --object-path -b --block-device -d --drive)'{-p,--object-path=}'[specify object]:object path:->object-paths' )
      ;;
      --options)
        opts[i]=( '(-o --options)'{-o,--options=}'[specify mount options]:mount options' )
      ;;
      --read-only)
        opts[i]=( '(-r --read-only)'{-r,--read-only} )
      ;;
      --size)
        opts[i]=( '(-s --size)'{-s,--size=}'[specify size]:size (bytes)' )
      ;;
    esac
  done
  shift words
  (( CURRENT-- ))
  _arguments -S -C '(-)--help[display usage information]' $opts && ret=0

  if [[ -n $state ]]; then
    params="$cmd $words[1] "
    case $state in
      block-devices) params+="--block-device" ca_opts=( -M "r:|/=* r:|=*" ) ;;
      drives) params+="--drive" ca_opts=( -M "r:|_=* r:|=*" ) ;;
      object-paths) params+="--object-path" ca_opts=( -f -M "r:|/=* r:|=*" ) ;;
    esac
    vals=( $(_call_program values $cmd complete "${(q)params}" $#params) )
    _description values expl $state_descr
    compadd "$expl[@]" $ca_opts -a vals && ret=0
  fi
  return ret
fi