Hello, completion-helper's suggestions aren't that useful in scenarios where multiple versions of packages are available/installed, for example when completing kernel(-devel) packages to remove etc. The fix should be easy, but the full nvra makes completion suggestions generally uglier than they were.
So... thoughts/objections about the attached patch?
>From e25f740bbebae7998a9e14d453720b42a0a751fa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ville=20Skytt=C3=A4?= <[email protected]> Date: Thu, 25 Oct 2012 00:06:05 +0300 Subject: [PATCH] bash completion: offer nvra instead of na strings when listing packages. Helps dealing with packages with multiple versions installed/available etc. --- completion-helper.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/completion-helper.py b/completion-helper.py index 05801d1..5b44c9d 100755 --- a/completion-helper.py +++ b/completion-helper.py @@ -45,10 +45,10 @@ class ListCompletionCommand(yumcommands.ListCommand): patterns=[get_pattern(extcmds)]) if extcmds[0] in ("installed", "all"): for pkg in ypl.installed: - print pkg.na + print pkg.nvra if extcmds[0] in ("available", "all"): for pkg in ypl.available: - print pkg.na + print pkg.nvra class RepoListCompletionCommand(yumcommands.RepoListCommand): def doCommand(self, base, basecmd, extcmds): -- 1.7.11.7
_______________________________________________ Yum-devel mailing list [email protected] http://lists.baseurl.org/mailman/listinfo/yum-devel
