* A key to delete a history item would be nice
@ 2012-12-29 21:22 Dave Yost
2013-01-03 23:17 ` Ivan Sichmann Freitas
0 siblings, 1 reply; 3+ messages in thread
From: Dave Yost @ 2012-12-29 21:22 UTC (permalink / raw)
To: zsh-workers
I’m using up-arrow to look back in history. Some of those history items are useless because they are mistakes.
It would be nice if there were a keystroke that would delete the current history item.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: A key to delete a history item would be nice
2012-12-29 21:22 A key to delete a history item would be nice Dave Yost
@ 2013-01-03 23:17 ` Ivan Sichmann Freitas
2013-01-04 3:58 ` Dave Yost
0 siblings, 1 reply; 3+ messages in thread
From: Ivan Sichmann Freitas @ 2013-01-03 23:17 UTC (permalink / raw)
To: Dave Yost; +Cc: zsh-workers
On Sat, Dec 29, 2012 at 01:22:02PM -0800, Dave Yost did gyre and gimble:
>I’m using up-arrow to look back in history. Some of those history items
>are useless because they are mistakes.
I would recommend using history-incremental-search-backward and
history-incremental-pattern-search-backward (the former has the default
binding of Control+r in emacs mode) even if you manage to delete items
from your history. They are much faster and enable you to search history
based in words or patterns.
>It would be nice if there were a keystroke that would delete the current history item.
AFAIK there's no default zle widget to delete a item from the history,
but I think you can achieve it by creating a custom zle widget (se
zshzle(1) manpage). However, there are ways to control what is recorded
in history, see options HIST_IGNORE_DUPS, HIST_IGNORE_SPACE and others
at zshoptions(1).
--
Ivan Sichmann Freitas
GNU/Linux user #509059
SDF Arpa Member http://isf.sdf.org/about.html
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: A key to delete a history item would be nice
2013-01-03 23:17 ` Ivan Sichmann Freitas
@ 2013-01-04 3:58 ` Dave Yost
0 siblings, 0 replies; 3+ messages in thread
From: Dave Yost @ 2013-01-04 3:58 UTC (permalink / raw)
To: Ivan Sichmann Freitas; +Cc: zsh-workers
Thanks for the suggestions. But my RFE stands. It is a useful thing to be able to clean up clutter. The feature I’m proposing does that.
On Thu 2013-01-03, at 03:17 PM, Ivan Sichmann Freitas <ivansichfreitas@gmail.com> wrote:
> On Sat, Dec 29, 2012 at 01:22:02PM -0800, Dave Yost did gyre and gimble:
>
>> I’m using up-arrow to look back in history. Some of those history items
>> are useless because they are mistakes.
>
> I would recommend using history-incremental-search-backward and
> history-incremental-pattern-search-backward (the former has the default
> binding of Control+r in emacs mode) even if you manage to delete items
> from your history. They are much faster and enable you to search history
> based in words or patterns.
>
>> It would be nice if there were a keystroke that would delete the current history item.
>
> AFAIK there's no default zle widget to delete a item from the history,
> but I think you can achieve it by creating a custom zle widget (se
> zshzle(1) manpage). However, there are ways to control what is recorded
> in history, see options HIST_IGNORE_DUPS, HIST_IGNORE_SPACE and others
> at zshoptions(1).
>
> --
> Ivan Sichmann Freitas
> GNU/Linux user #509059
> SDF Arpa Member http://isf.sdf.org/about.html
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-01-04 4:58 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-12-29 21:22 A key to delete a history item would be nice Dave Yost
2013-01-03 23:17 ` Ivan Sichmann Freitas
2013-01-04 3:58 ` Dave Yost
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).