fish-shell/share/functions/__fish_print_pacman_repos.fish
Fabian Homborg d591cebf44 Introduce __fish_print_pacman_repos helper
This is used in at least 4 places, all of which have a bug in that they
print "options" as a valid repo. It seems better to fix it once,
especially given that there are tons of AUR helpers and pacman wrappers,
all of which might need this info.
2015-09-25 13:37:39 +02:00

3 lines
195 B
Fish

function __fish_print_pacman_repos --description "Print the repositories configured for arch's pacman package manager"
sed -n -e 's/\[\(.\+\)\]/\1/p' /etc/pacman.conf | grep -v "#\|options"
end