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

Re: [PATCH] EXTENDED_HISTORY documentation typo



On 27 October 2011 20:50, Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx> wrote:
> On Oct 27,  6:12pm, Mikael Magnusson wrote:
> } Subject: Re: [PATCH] EXTENDED_HISTORY documentation typo
> }
> } % history -dD
> }     1  18:06  0:00  HISTFILE=/tmp/test
> }     2  18:06  0:00  HISTSIZE=50
> }     3  18:06  0:00  SAVEHIST=50
> }     4  18:06  0:00  setopt incappendhist
> }     5  18:06  0:00  setopt incappendhistory
> }     6  18:06  0:00  cat /tmp/test
> }     7  18:06  0:00  setopt extendedhistory
> }     8  18:06  0:00  cat /tmp/test
> }     9  18:06  0:05  sleep 5
> }    10  18:07  0:00  cat /tmp/test
> }
> } At first i thought maybe it's one of my local patches, but i get the
> } same result on a remote host running 4.3.10.
>
> This is exactly what I'd expect.  Zsh doesn't even bother storing the
> time delta if extended history isn't set.  Hence you get the delta
> at event 9 after having set the option at event 7.
>
> There isn't a HIST_REVISIONIST option. :-)

Hm? I ran the sleep after I did setopt extendedhistory. Note also that
the time delta 0:05 is output by history -dD but isn't stored in the
history file. You didn't quote the histfile excerpt:

setopt extendedhistory
: 1319731616:0;cat /tmp/test
: 1319731618:0;sleep 5
: 1319731624:0;cat /tmp/test


-- 
Mikael Magnusson



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