All of lore.kernel.org
 help / color / mirror / Atom feed
* --interactive mode: readline support ⌨⬆
@ 2017-07-20  8:21 Marcel Partap
  2017-07-20  8:47 ` Martin Ågren
  2017-07-20 16:53 ` Leah Neukirchen
  0 siblings, 2 replies; 6+ messages in thread
From: Marcel Partap @ 2017-07-20  8:21 UTC (permalink / raw)
  To: git

Dear git devs,
wouldn't it be great to have the power of readline added to the power of git interactive commands? Yes, rlwrap will do the job, but still.
Or am I missing something obvious? Am using debian's 2.11.0-2 ...

#BestRegards/Marcel Partap

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: --interactive mode: readline support ⌨⬆
  2017-07-20  8:21 --interactive mode: readline support ⌨⬆ Marcel Partap
@ 2017-07-20  8:47 ` Martin Ågren
  2017-07-20  9:20   ` Marcel Partap
  2017-07-20 16:53 ` Leah Neukirchen
  1 sibling, 1 reply; 6+ messages in thread
From: Martin Ågren @ 2017-07-20  8:47 UTC (permalink / raw)
  To: Marcel Partap; +Cc: Git Mailing List

On 20 July 2017 at 10:21, Marcel Partap <mpartap@gmx.net> wrote:
> wouldn't it be great to have the power of readline added to the power of git interactive commands? Yes, rlwrap will do the job, but still.
> Or am I missing something obvious?

Well maybe *I* am missing something obvious. :) Could you be a bit
more specific? What is the use-case? Once this feature were in place,
what would it look like? Could you give an example of what you as a
user would do to solve some particular problem -- and how that differs
from how you would solve it today?

Martin

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: --interactive mode: readline support ⌨⬆
  2017-07-20  8:47 ` Martin Ågren
@ 2017-07-20  9:20   ` Marcel Partap
  2017-07-20 11:50     ` Martin Ågren
  0 siblings, 1 reply; 6+ messages in thread
From: Marcel Partap @ 2017-07-20  9:20 UTC (permalink / raw)
  To: Martin Ågren; +Cc: Git Mailing List

Ok very good point Martin ; )
I nefariously hid one obvious use case as trailing emoji™ in the subject, but a better way to make a point is to properly explain.
So the readline library powers the advanced line editing capabilities behind f.e. the bash or the ipython shell. Besides navigating with the cursor keys, it provides a history function accessible by the up cursor key ⌨⬆ .
At the moment, git interactive mode seems (?) not to make use of it, so there's no line editing at all. A typo at the beginning of a line must be corrected by reverse deleting up to it, then retyping the rest unchanged. With readline, the home/end keys for jumping to beginning or end work, as do the left/right keys in a familiar way.
The history function comes in handy when f.e. repeatedly using `git clean -i` and feeding the "filter by pattern" command a string like "*.patch". Like, that's the use case that prompted me to write to this list. : )

#Best Regards/Marcel

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: --interactive mode: readline support ⌨⬆
  2017-07-20  9:20   ` Marcel Partap
@ 2017-07-20 11:50     ` Martin Ågren
  2017-07-20 12:06       ` Marcel Partap
  0 siblings, 1 reply; 6+ messages in thread
From: Martin Ågren @ 2017-07-20 11:50 UTC (permalink / raw)
  To: Marcel Partap; +Cc: Git Mailing List

On 20 July 2017 at 11:20, Marcel Partap <mpartap@gmx.net> wrote:
> So the readline library powers the advanced line editing capabilities behind f.e. the bash or the ipython shell. Besides navigating with the cursor keys, it provides a history function accessible by the up cursor key ⌨⬆ .
> At the moment, git interactive mode seems (?) not to make use of it, so there's no line editing at all. A typo at the beginning of a line must be corrected by reverse deleting up to it, then retyping the rest unchanged. With readline, the home/end keys for jumping to beginning or end work, as do the left/right keys in a familiar way.
> The history function comes in handy when f.e. repeatedly using `git clean -i` and feeding the "filter by pattern" command a string like "*.patch". Like, that's the use case that prompted me to write to this list. : )

Ok, I see. When I saw your first mail, I was thinking about "git
rebase -i" and thought, "how could that possibly help?". :) I have no
idea what it would take to implement this (portably!) in git.

Martin

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: --interactive mode: readline support ⌨⬆
  2017-07-20 11:50     ` Martin Ågren
@ 2017-07-20 12:06       ` Marcel Partap
  0 siblings, 0 replies; 6+ messages in thread
From: Marcel Partap @ 2017-07-20 12:06 UTC (permalink / raw)
  To: Martin Ågren; +Cc: Git Mailing List

Haha, totally slipped by me that there exist two kinds of interactive mode. Not that I haven't used both... Sorry for overlooking/being to unspecific.

#Regards/Marcel X )

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: --interactive mode: readline support ⌨⬆
  2017-07-20  8:21 --interactive mode: readline support ⌨⬆ Marcel Partap
  2017-07-20  8:47 ` Martin Ågren
@ 2017-07-20 16:53 ` Leah Neukirchen
  1 sibling, 0 replies; 6+ messages in thread
From: Leah Neukirchen @ 2017-07-20 16:53 UTC (permalink / raw)
  To: git

Marcel Partap <mpartap@gmx.net> writes:

> Dear git devs,
> wouldn't it be great to have the power of readline added to the power
> of git interactive commands? Yes, rlwrap will do the job, but still.
> Or am I missing something obvious? Am using debian's 2.11.0-2 ...

Just use "rlwrap git clean -i".

-- 
Leah Neukirchen  <leah@vuxu.org>  http://leah.zone


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2017-07-20 17:00 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-07-20  8:21 --interactive mode: readline support ⌨⬆ Marcel Partap
2017-07-20  8:47 ` Martin Ågren
2017-07-20  9:20   ` Marcel Partap
2017-07-20 11:50     ` Martin Ågren
2017-07-20 12:06       ` Marcel Partap
2017-07-20 16:53 ` Leah Neukirchen

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.