zsh-workers
 help / color / mirror / code / Atom feed
From: Richard Hartmann <richih.mailinglist@gmail.com>
To: Bart Schaefer <schaefer@brasslantern.com>
Cc: zsh-workers@zsh.org
Subject: Re: Proposed feature: Selectively avoid adding to history (with code)
Date: Tue, 23 Feb 2010 10:41:32 +0100	[thread overview]
Message-ID: <2d460de71002230141v3bfb9673gdc35c391cea3f81@mail.gmail.com> (raw)
In-Reply-To: <100222184752.ZM26580@torch.brasslantern.com>

On Tue, Feb 23, 2010 at 03:47, Bart Schaefer <schaefer@brasslantern.com> wrote:

> It'd be more useful if I could retroactively delete the last several
> commands from my history, because I never remember to turn this sort
> of thing on before I start testing. :-)

There is something on the mailing list about that. I used to use it, but
don't need to any more, as I have become better at opening new
shells for testing & doing HISTFILE=''.


> I'm not sure what you mean by "should be a _function"?

A built-in function that can be overriden.


> HIST_DISABLE or would probably be a better name.  Won't one of the side-
> effects be that you can't find those commands in the interactive history
> either?

I wanted to express that the effect is temporary and normal operation can
be resumed with the press of a button, so to speak. Also, that everything
before or after will still be stored.


>  I'd like stuff to remain in the interactive history but somehow
> be tagged so they're never written to $HISTFILE, which brings me to ...

Sounds useful but potentially confusing.


> A tagging effect probably does need to be controlled by an option, as
> the alternative is a builtin you can only call from zshaddhistory() or
> some such; but I think for what you've got here, your approach is fine.

If the topic of tagging comes up, there is other stuff that could be put
into the enhanced history. For example, PWD comes to mind.


Richard


      parent reply	other threads:[~2010-02-23  9:49 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-02-22 17:42 Richard Hartmann
2010-02-23  2:47 ` Bart Schaefer
2010-02-23  7:57   ` Mikael Magnusson
2010-02-23  9:42     ` Richard Hartmann
2010-02-23  9:41   ` Richard Hartmann [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=2d460de71002230141v3bfb9673gdc35c391cea3f81@mail.gmail.com \
    --to=richih.mailinglist@gmail.com \
    --cc=schaefer@brasslantern.com \
    --cc=zsh-workers@zsh.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).