Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 109697 - app-portage/genlop: bash-completion does not support all command-line arguments
Summary: app-portage/genlop: bash-completion does not support all command-line arguments
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Portage Tools Team
URL:
Whiteboard:
Keywords: InVCS
Depends on:
Blocks:
 
Reported: 2005-10-18 05:37 UTC by Renat Golubchyk
Modified: 2013-01-19 20:28 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
support for more command-line arguments (genlop.bash-completion.patch,2.43 KB, patch)
2005-10-18 05:45 UTC, Renat Golubchyk
Details | Diff
changes 'cd' to 'builtin cd' (genlop.bash-completion.builtin_cd_patch.patch,661 bytes, patch)
2005-10-18 07:32 UTC, Renat Golubchyk
Details | Diff
combined patch for genlop 0.30.7 (genlop.bash-completion.0.30.7.patch,2.75 KB, patch)
2007-06-12 11:36 UTC, Renat Golubchyk
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Renat Golubchyk 2005-10-18 05:37:53 UTC
genlop understands more arguments than the bash_completion script now supports.
I added them (and cleaned up the code a little :-) )

Reproducible: Always
Steps to Reproduce:
e.g. type "genlop --d" and hit TAB
Actual Results:  
nothing changes

Expected Results:  
genlop --date
Comment 1 Renat Golubchyk 2005-10-18 05:45:48 UTC
Created attachment 70930 [details, diff]
support for more command-line arguments

This patch adds support for one-letter arguments and --date.

It fixes the "unary operator expected" bug. I got that message every time I hit
TAB. The bug happened here:
  if [ ${portagedir} = "" ]

Cleaned up the code a little, so that it uses bash-internal [[ ... ]] instead
of [ ... ] for conditions.
Comment 2 Aaron Walker (RETIRED) gentoo-dev 2005-10-18 07:10:14 UTC
genlop has it's own bash completion from upstream so reassigning this to the
genlop maintainers.
Comment 3 Aaron Walker (RETIRED) gentoo-dev 2005-10-18 07:14:39 UTC
btw, while I'm here, one thing that's always bugged me about their completion is
they use 'cd' instead of 'builtin cd'.  Otherwise folks who have cd redefined to
display stuff upon entering a directory (todo lists in my case) get their
completion messed up due to the ouput. Can we get that fixed as well?
Comment 4 Renat Golubchyk 2005-10-18 07:32:43 UTC
Created attachment 70941 [details, diff]
changes 'cd' to 'builtin cd'
Comment 5 Renat Golubchyk 2005-10-18 07:36:15 UTC
(In reply to comment #3)
> btw, while I'm here, one thing that's always bugged me about their completion is
> they use 'cd' instead of 'builtin cd'.  Otherwise folks who have cd redefined to
> display stuff upon entering a directory (todo lists in my case) get their
> completion messed up due to the ouput. Can we get that fixed as well?

I'm wondering, is it possible to define a global alias cd='builtin cd' instead
of writing 'builtin cd' in every completion function? It should be seen only by
all the bash_completion scripts, of course.
Comment 6 Renat Golubchyk 2007-06-12 11:36:58 UTC
Created attachment 121795 [details, diff]
combined patch for genlop 0.30.7

I've updated the patches to the latest version (0.30.7) of genlop.
Comment 7 Jeremy Olexa (darkside) (RETIRED) archtester gentoo-dev Security 2011-02-09 05:18:42 UTC
(In reply to comment #6)
> Created an attachment (id=121795) [details]
> combined patch for genlop 0.30.7
> 
> I've updated the patches to the latest version (0.30.7) of genlop.
> 

Thanks for the patch Renet. I'm not sure why this has not been addressed by the tools-portage team. Here is a friendly poke, as it probably slipped through the cracks :)
Comment 8 Paul Varner (RETIRED) gentoo-dev 2013-01-19 20:28:13 UTC
Thanks for the patch, released in genlop-0.30.9