fork/fish-shell
git clone https://git.julia.blue/fork/fish-shell
a53db7256
master
1# localization: skip(private) 2function __fish_print_rpm_packages 3type -q -f rpm /usr/share/yum-cli/completion-helper.py|| return 1 4 5# We do not use "--installed", but we still allow passing it. 6argparse i/installed --$argv 7or return 1 8 9if type -q -f /usr/share/yum-cli/completion-helper.py 10# Remove package version information from output and pipe into cache file 11__fish_cached -t21600 -k yum-completion-helper --'/usr/share/yum-cli/completion-helper.py list all -d 0 -C | sed "s/\\..*/\\tPackage/"' 12return 13end 14 15# Rpm is too slow for this job, so we set it up to do completions 16# as a background job and cache the results. 17if type -q -f rpm 18# Remove package version information from output and pipe into cache file 19__fish_cached -t250 --"rpm -qa | sed -e 's/-[^-]*-[^-]*\$/\\t'Package'/'" 20return 21end 22end