diff options
author | 2011-01-11 23:22:27 +1100 | |
---|---|---|
committer | 2011-01-11 23:22:27 +1100 | |
commit | 2583638f4bb0b1b46f82f6ed2320a644f2c8e64b (patch) | |
tree | 54b3f58d19ea5519402472a14e740e31f27bfa81 /share/functions/__fish_print_packages.fish | |
parent | dcecab384acc003beb43859ee2143c9b78795d55 (diff) | |
parent | 11360b018fd797a60705b0aa74c8001d006562ed (diff) |
Merge commit 'refs/merge-requests/8' of git://gitorious.org/fish-shell/fish-shell into merge_request_8
Diffstat (limited to 'share/functions/__fish_print_packages.fish')
-rw-r--r-- | share/functions/__fish_print_packages.fish | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/share/functions/__fish_print_packages.fish b/share/functions/__fish_print_packages.fish index 8dae87b9..1991bd6d 100644 --- a/share/functions/__fish_print_packages.fish +++ b/share/functions/__fish_print_packages.fish @@ -46,9 +46,17 @@ function __fish_print_packages # This completes the package name from the portage tree. # True for installing new packages. Function for printing # installed on the system packages is in completions/emerge.fish - if type -f emerge >/dev/null - emerge -s \^(commandline -tc) |sgrep "^*" |cut -d\ -f3 |cut -d/ -f2 + + # eix is MUCH faster than emerge so use it if it is available + if type -f eix > /dev/null + eix --only-names "^"(commandline -tc) | cut -d/ -f2 return + else + # FIXME? Seems to be broken + if type -f emerge >/dev/null + emerge -s \^(commandline -tc) |sgrep "^*" |cut -d\ -f3 |cut -d/ -f2 + return + end end end |