* History not deduplicated when zsh is killed by SIGHUP
@ 2020-12-05 10:04 Robert Cegliński
0 siblings, 0 replies; only message in thread
From: Robert Cegliński @ 2020-12-05 10:04 UTC (permalink / raw)
To: zsh-workers
[-- Attachment #1: Type: text/plain, Size: 730 bytes --]
Hello,
I believe I discovered an issue with saving the history file. Here's a
minimal reproducer:
~ ❯ mkdir /tmp/zsh-repro
~ ❯ print
"HISTFILE=/tmp/zsh-repro/histfile;HISTSIZE=100;SAVEHIST=100;setopt
hist_ignore_all_dups" > /tmp/zsh-repro/.zshrc
~ ❯ ZDOTDIR=/tmp/zsh-repro zsh
rcarch% ls >/dev/null
rcarch% exit
~ ❯ ZDOTDIR=/tmp/zsh-repro zsh
rcarch% ls >/dev/null # scroll up 2 times
rcarch% kill -SIGHUP $$ # or just close the terminal
~ ❯ cat /tmp/zsh-repro/histfile
ls >/dev/null
exit
ls >/dev/null
kill -SIGHUP $$
If we launch zsh again and scroll up the history, we will receive duplicate
entries.
OS: Arch Linux
zsh: 5.8, also reproducible on current master
---
Robert
[-- Attachment #2: Type: text/html, Size: 951 bytes --]
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2020-12-05 10:05 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-05 10:04 History not deduplicated when zsh is killed by SIGHUP Robert Cegliński
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).