[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gnu-arch-users] tla-bash-complete usability

From: Robert Anderson
Subject: [Gnu-arch-users] tla-bash-complete usability
Date: 01 Sep 2003 10:51:24 -0700

On Mon, 2003-09-01 at 10:33, Jonas Diemer wrote:
> On 01 Sep 2003 10:13:53 -0700
> Robert Anderson <address@hidden> wrote:
> > > revision completion though? Maybe have the script just complete to
> > > 
> > > cat--branch--version--
> > > 
> > > whenever a revision is a valid argument. this should save a lot of
> > > typing work but still won't give possible hundreds of revisions for
> > > choice.
> > 
> > I think it's ok to list all the revisions.  It's the same thing for
> > file completion in a large directory.  archive cycling for this and
> > other reasons ought to keep revision counts from reaching the 1000's,
> > I suspect.
> Well, I still don't like that though... Not only will it mess up the
> completion output,

How so?

 but revision completion is also the most ressource
> intense task: The script would have to recursively get all existing
> versions, then get all revision for each version and finally concenate
> them together.

I don't understand why.  It should interactively complete each piece of
the version, so that when it comes time to list revisions, you only have
the revisions associated with that version.  Ex:

tla replay --exact cat[TAB]
tla replay --exact cat--branch1[TAB]
tla replay --exact cat--branch1--2.0[TAB]

> The gain in typing speed is very little compared to the costs.

I don't believe it will be for the behavior above.

>One could point out that listing all revisions might make it easier for the 
> to remember/know which version he wants...

Exactly.  That's one of the main uses of context-sensitive completion,
IMO. It's effectively a menu.

> Another reason is that some commands (e.g. tla get) are also satisfied
> with a version. So we should just do version completion if a revision is
> a valid argument, maybe completing to base-0 or patch- if a version is
> followed by two dashes.

I think if the user gets to the full version and presses [TAB], then
they want revisions (and if revisions are a valid input in that
context).  Otherwise they can just hit [enter] at that point.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]