fork/fish-shell
git clone https://git.julia.blue/fork/fish-shell
a9618477e
master
1# 2# Completions for the yum command 3# 4 5# All yum commands 6 7# Test if completing using package names is appropriate 8function __fish_yum_package_ok 9for iin ( commandline -pxc) 10if contains --$i update upgrade remove erase install reinstall 11return 0 12end 13end 14return 1 15end 16 17complete -c yum -n __fish_use_subcommand -xa install -d"Install the latest version of a package" 18complete -c yum -n __fish_use_subcommand -xa'update upgrade' -d"Update specified packages (defaults to all packages)" 19complete -c yum -n __fish_use_subcommand -xa check-update -d"Print list of available updates" 20complete -c yum -n __fish_use_subcommand -xa'remove erase' -d"Remove the specified packages and packages that depend on them" 21complete -c yum -n __fish_use_subcommand -xa list -d"List available packages" 22complete -c yum -n __fish_use_subcommand -xa info -d"Describe available packages" 23complete -c yum -n __fish_use_subcommand -xa'provides whatprovides' -d"Find package providing a feature or file" 24complete -c yum -n __fish_use_subcommand -xa search -d"find packages matching description regexp" 25complete -c yum -n __fish_use_subcommand -xa clean -d"Clean up cache directory" 26complete -c yum -n __fish_use_subcommand -xa generate-rss -d"Generate rss changelog" 27 28complete -c yum -n __fish_yum_package_ok -a"(__fish_print_rpm_packages)" 29 30complete -c yum -s h -l help -d"Display help and exit" 31complete -c yum -s y -d"Assume yes to all questions" 32complete -c yum -s c -d"Configuration file" -r 33complete -c yum -s d -d"Set debug level" -x 34complete -c yum -s e -d"Set error level" -x 35complete -c yum -s t -l tolerant -d"Be tolerant of errors in commandline" 36complete -c yum -s R -d"Set maximum delay between commands" -x 37complete -c yum -s c -d"Run commands from cache" 38complete -c yum -l version -d"Display version and exit" 39complete -c yum -l installroot -d"Specify installroot" -r 40complete -c yum -l enablerepo -d"Enable repository" -r 41complete -c yum -l disablerepo -d"Disable repository" -r 42complete -c yum -l obsoletes -d"Enables obsolets processing logic" 43complete -c yum -l rss-filename -d"Output rss-data to file" -r 44complete -c yum -l exclude -d"Exclude specified package from updates" -a"(__fish_print_rpm_packages)" 45 46complete -c yum -n'contains list (commandline -pxc)' -a all -d'List all packages' 47complete -c yum -n'contains list (commandline -pxc)' -a available -d'List packages available for installation' 48complete -c yum -n'contains list (commandline -pxc)' -a updates -d'List packages with updates available' 49complete -c yum -n'contains list (commandline -pxc)' -a installed -d'List installed packages' 50complete -c yum -n'contains list (commandline -pxc)' -a extras -d'List packages not available in repositories' 51complete -c yum -n'contains list (commandline -pxc)' -a obsoletes -d'List packages that are obsoleted by packages in repositories' 52 53complete -c yum -n'contains clean (commandline -pxc)' -x -a packages -d'Delete cached package files' 54complete -c yum -n'contains clean (commandline -pxc)' -x -a headers -d'Delete cached header files' 55complete -c yum -n'contains clean (commandline -pxc)' -x -a all -d'Delete all cache contents'