From: Chong Yidong Date: Thu, 23 Oct 2008 22:09:09 +0000 (+0000) Subject: (pcomplete/rpm): Make "rpm -qp" use file completion. X-Git-Tag: emacs-pretest-23.0.90~2220 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=1258fedec4c20f9edec4c01ad7d7fffa4b1437b6;p=emacs.git (pcomplete/rpm): Make "rpm -qp" use file completion. --- diff --git a/lisp/pcmpl-rpm.el b/lisp/pcmpl-rpm.el index 99e42e87edd..19dca7564a5 100644 --- a/lisp/pcmpl-rpm.el +++ b/lisp/pcmpl-rpm.el @@ -135,7 +135,9 @@ You can use \\[report-emacs-bug] to do so." (pcmpl-rpm-all-query "--requires"))))) (if (pcomplete-match "^-" 0) (pcomplete-opt "af.p(pcmpl-rpm-files)ilsdcvR") - (pcomplete-here (pcmpl-rpm-packages))))) + (if (pcomplete-test "-[^-]*p" 'first 1) + (pcomplete-here (pcmpl-rpm-files)) + (pcomplete-here (pcmpl-rpm-packages)))))) ((pcomplete-test "--pipe") (pcomplete-here* (funcall pcomplete-command-completion-function))) ((pcomplete-test "--rmsource")