Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: SSD-friendly history



On Wed, Oct 05, 2022 at 03:50:43PM -0700, Bart Schaefer wrote:
> On Wed, Oct 5, 2022 at 2:34 PM Dominik Vogt <dominik.vogt@xxxxxx> wrote:
> > I'd really like to have a mechanism that appends to the history
> > until some maximum size is reached and then truncates it to some
> > much smaller size
>
> Setting INC_APPEND_HISTORY will cause the file to be rewritten only
> when it reaches 20% larger than SAVEHIST.  There's no option to make
> that greater than 20% at this point.
>
> However, this would be a reason to make SAVEHIST a lot larger than
> HISTSIZE.

Disk space is not an issue.  So, if I set

  SAVEHIST=120000
  HISTSIZE=100000

Then only 100.000 lines are loaded when the shell starts?

--

But how does this interact with duplicate handling, especially
with HIST_EXPIRE_DUPS_FIRST?

Ciao

Dominik ^_^  ^_^

--

Dominik Vogt




Messages sorted by: Reverse Date, Date, Thread, Author