The following commit has been merged in the master branch:
commit f95b6dcf0e80d846c216c74ace983de90e79a582
Author: James Vega <[email protected]>
Date: Tue Jul 13 20:09:55 2010 -0400
debc: Update bash completion to complete *.changes files and package names.
Closes: #584703
Signed-off-by: James Vega <[email protected]>
diff --git a/debian/changelog b/debian/changelog
index c0b45f5..04e2917 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,6 +1,9 @@
devscripts (2.10.65.1) UNRELEASED; urgency=low
- * debi/debc: Call changelog_parse correctly. (Closes: #588947)
+ * debc:
+ + Call changelog_parse correctly. (Closes: #588947)
+ + Update bash completion to complete *.changes files and package names.
+ Thanks to Stefano Rivera for the patch. (Closes: #584703)
-- James Vega <[email protected]> Tue, 13 Jul 2010 18:48:29 -0400
diff --git a/scripts/pkgnames.bash_completion b/scripts/pkgnames.bash_completion
index 1486eb8..8a8f98e 100644
--- a/scripts/pkgnames.bash_completion
+++ b/scripts/pkgnames.bash_completion
@@ -8,5 +8,16 @@ _pkg_names()
return 0
}
-complete -F _pkg_names wnpp-alert wnpp-check mk-build-deps rmadison mass-bug
debsnap dd-list build-rdeps who-uploads transition-check getbuildlog dcontrol
grep-excuses rc-alert debcheckout bts whodepends dget pts-subscribe debc
pts-unsubscribe
+_debc()
+{
+ local cur
+ cur="${COMP_WORDS[COMP_CWORD]}"
+ COMPREPLY=($(compgen -f -X '!*.changes' -- "$cur"))
+ if echo "$cur" | grep -qs '^[a-z0-9+.-]*$'; then
+ COMPREPLY=(${comprep...@]} $(apt-cache pkgnames -- $cur 2> /dev/null))
+ fi
+ return 0
+}
+complete -F _pkg_names wnpp-alert wnpp-check mk-build-deps rmadison mass-bug
debsnap dd-list build-rdeps who-uploads transition-check getbuildlog dcontrol
grep-excuses rc-alert bts whodepends dget pts-subscribe debc pts-unsubscribe
+complete -o dirnames -F _debc debc
--
Git repository for devscripts
--
To unsubscribe, send mail to [email protected].