Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: [PATCH 1/2] Set SAVEHIST to $HISTSIZE by default
- X-seq: zsh-workers 50574
- From: Felipe Contreras <felipe.contreras@xxxxxxxxx>
- To: Daniel Shahaf <d.s@xxxxxxxxxxxxxxxxxx>
- Cc: zsh-workers@xxxxxxx
- Subject: Re: [PATCH 1/2] Set SAVEHIST to $HISTSIZE by default
- Date: Fri, 2 Sep 2022 04:29:30 -0500
- Archived-at: <https://zsh.org/workers/50574>
- In-reply-to: <20220902085904.GF5920@tarpaulin.shahaf.local2>
- List-id: <zsh-workers.zsh.org>
- References: <20220831031854.27312-1-felipe.contreras@gmail.com> <20220831031854.27312-2-felipe.contreras@gmail.com> <20220902085904.GF5920@tarpaulin.shahaf.local2>
On Fri, Sep 2, 2022 at 3:59 AM Daniel Shahaf <d.s@xxxxxxxxxxxxxxxxxx> wrote:
> Felipe Contreras wrote on Tue, Aug 30, 2022 at 22:18:53 -0500:
> > If they are the same, this makes it clearer that they are the same.
> >
> > Signed-off-by: Felipe Contreras <felipe.contreras@xxxxxxxxx>
> > ---
> > Etc/FAQ.yo | 2 +-
> > Functions/Newuser/zsh-newuser-install | 2 +-
> > 2 files changed, 2 insertions(+), 2 deletions(-)
> >
> > diff --git a/Etc/FAQ.yo b/Etc/FAQ.yo
> > index 8c795685a..dd573767e 100644
> > --- a/Etc/FAQ.yo
> > +++ b/Etc/FAQ.yo
> > @@ -1631,7 +1631,7 @@ label(321)
> > verb(
> > HISTSIZE=200
> > HISTFILE=~/.zsh_history
> > - SAVEHIST=200
> > + SAVEHIST=$HISTSIZE
>
> Personally, I'm not going to commit this since I find the increased
> semantic precision / DRY compliance to be outweighed by the reduced
> readability (both here and in the code below, but for different
> reasons).
But you only need to read it *once* and forget about it forever (or at
least as long as you keep the same history strategy).
On the other hand you might change HISTSIZE more than once. One user
mentioned he added one 0 every time he hit the limit.
--
Felipe Contreras
Messages sorted by:
Reverse Date,
Date,
Thread,
Author