Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Excluding command from history list
- X-seq: zsh-users 19773
- From: Ramkumar Ramachandra <artagnon@xxxxxxxxx>
- To: zsh-users@xxxxxxx
- Subject: Excluding command from history list
- Date: Fri, 23 Jan 2015 12:32:26 -0500
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:from:date:message-id:subject:to:content-type; bh=DmOLzhIAx5Kexc4SnGxGksaHOME+8d47DKZ5hjhyuxw=; b=u2eVCkj0voJt42HWL0iHu8kAgf9/KPYJMb8u34Oo7HS1kefwwh0X02X7cGLZ5M/soU WiVw0HpQX5Es1qOY1YwZTdAvGNthVU1ja50NLH95NVr+d8d6StJ2aYKCvDO5msbuHRi2 ay3CxeWdg1DRYSTwCfMtkmareYvgOdRcjQ9yDaPupz0rayKgYSzvEonlMbo31Zt++EoB /dbz6Ez8DU5aBnBuQy66ydIJqY86rAgbVzsei84DW2h0UmQzMGs5EVzfN+uawtzitaYN SeRB5d/9iBE4u34hyWu7EWRBlVj36FclaSVM7GqoS6oqVz6qoV3Dqn8DAB24FbhhbuCR 7/LQ==
- List-help: <mailto:zsh-users-help@zsh.org>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:zsh-users@zsh.org>
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
Hi,
I have this problem where I'm always at the risk of hitting RET at the
wrong command during a ^R survey. Especially if you have commit access
to an important codebase,
$ git svn dcommit
or
$ git push -f
might be a disastrous at the wrong time. Hence, I want to exclude
*dcommit* from the history list; excluding it from the history file is
pretty simple:
zshaddhistory () {
[[ $1 != *dcommit* ]]
}
... but I haven't figured out how to do it for the history list, which
is what really matters (because you're always looking for recent
history).
Thanks.
Ram
Messages sorted by:
Reverse Date,
Date,
Thread,
Author