diff --git a/share/completions/emaint.fish b/share/completions/emaint.fish index 547fe0a48..0b619e87a 100644 --- a/share/completions/emaint.fish +++ b/share/completions/emaint.fish @@ -1,3 +1,8 @@ +function __fish_portage_print_repository_names --description 'Print the names of all configured repositories' + # repos.conf may be a file or a directory + find /etc/portage/repos.conf -type f -exec cat '{}' + | string replace -r --filter '^\s*\[([[:alnum:]_][[:alnum:]_-]*)\]' '$1' | string match -v -e DEFAULT +end + ## Global Opts complete -c emaint -s h -l help -d "Show this help message and exit" complete -c emaint -s c -l check -d "Check for problems" diff --git a/share/functions/__fish_portage_print_repository_names.fish b/share/functions/__fish_portage_print_repository_names.fish deleted file mode 100644 index d3a898ac1..000000000 --- a/share/functions/__fish_portage_print_repository_names.fish +++ /dev/null @@ -1,4 +0,0 @@ -function __fish_portage_print_repository_names --description 'Print the names of all configured repositories' - # repos.conf may be a file or a directory - find /etc/portage/repos.conf -type f -exec cat '{}' + | string replace -r --filter '^\s*\[([[:alnum:]_][[:alnum:]_-]*)\]' '$1' | string match -v -e DEFAULT -end