1#compdef module-assistant m-a 2 3typeset -a _module_assistant_commands 4 5_module_assistant_commands=( 6 'update[synchronize version index files]' 7 'prepare[install required kernel headers package]' 8 'fakesource[install required kernel source package]' 9 'list[a print a list of details about available packages]' 10 'list-available[b print a list of details about available packages]' 11 'la[c print a list of details about available packages]' 12 'list-installed[ print a list of details about installed packages]' 13 'li[print a list of details about installed packages]' 14 'search[search for packages]' 15 'get[install specified source package]' 16 'build[build specified packages]' 17 'install[install specified packages]' 18 'auto-install[do all necessary steps to install specified packages]' 19 'clean[clear build directories of the kernel packages]' 20 'purge[clear cache and remove all binary packages of source package]' 21) 22 23_arguments -A \ 24 '(-h --help)'{-h,--help}'[print help screen]' \ 25 '(-v --verbose)'{-v,--verbose}'[be verbose, show full paths, etc.]' \ 26 '(-q --quiet)'{-q,--quiet}'[the opposite of verbose]' \ 27 '(-n --no-rebuild)'{-n,--no-rebuild}'[do not rebuild when package exists]' \ 28 '(-i --ignore-failures)'{-i,--ignore-failures}'[do not stop on build failures]' \ 29 '(-s --apt-search)'{-s,--apt-search}'[search for installation candidates in the Debian archive]' \ 30 '(-f --force)'{-f,--force}'[force using new versions even when old ones exist]' \ 31 '(-u --userdir)'{-u,--userdir}'[specify a (writable) replacement directory for /var&/usr]:dir:_files -/' \ 32 '(-l --kvers-list)'{-l,--kvers-list}'[list of kernel versions to work on (default: current version)]:kernel version list:' \ 33 '(-k --kernel-dir)'{-k,--kernel-dir}'[list of kernel headers/source directories, comma separated]:list of dirs:_files -/' \ 34 '(-t --text-mode)'{-t,--text-mode}'[no progress bars]' \ 35 '1:list of commands:_values -s , subcommands "${_module_assistant_commands[@]}"' \ 36 '*:packages: compadd /usr/src/modass/var_cache_modass/*.avail_version(N:t:r) /var/cache/modass/*.avail_version(N:t:r)' 37 38