Package: fish
Version: 1.23.0-6
Severity: wishlist
Tags: patch
--- Please enter the report below this line. ---
Could you add the completion in apt-cache for package names?
In order to ease your work, I join a patch… I hope it will be useful.
Thanks,
--- System information. ---
Architecture: i386
Kernel: Linux 2.6.26-1-686
Debian Release: 5.0
1 testing security.debian.org
1 testing ftp.fr.debian.org
--- Package information. ---
Depends (Version) | Installed
===================================-+-====================
libc6 (>= 2.7-1) | 2.7-18
libncurses5 (>= 5.6+20071006-3) | 5.7+20090214-1
bc | 1.06.94-3
lynx |
OR www-browser |
--- share/completions/apt-cache.fish.orig 2009-03-06 18:13:05.000000000 +0000
+++ share/completions/apt-cache.fish 2009-03-06 18:13:25.000000000 +0000
@@ -29,3 +29,14 @@
complete -r -c apt-cache -s c -l config-file --description "Specify config file"
complete -x -c apt-cache -s o -l option --description "Specify options"
+function __fish_apt-cache_use_package --description 'Test if apt command should have packages as potential completion'
+ for i in (commandline -opc)
+ if contains -- $i contains show showpkg showsrc depends rdepends dotty policy
+ return 0
+ end
+ end
+ return 1
+end
+
+complete -c apt-cache -n '__fish_apt-cache_use_package' -a '(__fish_print_packages)' --description 'Package'
+