Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Weird history behavior
- X-seq: zsh-users 27839
- From: Adam Cooper <adam@xxxxxxxxxxxxxxxxx>
- To: Zsh Users <zsh-users@xxxxxxx>
- Subject: Re: Weird history behavior
- Date: Wed, 8 Jun 2022 12:55:28 -0400
- Archived-at: <https://zsh.org/users/27839>
- In-reply-to: <CAH+w=7bzCH5jzVszH9wb0qfA+PhhVwUuJTOMUJXuE0eQJJQ+=g@mail.gmail.com>
- List-id: <zsh-users.zsh.org>
- Mail-followup-to: Zsh Users <zsh-users@xxxxxxx>
- References: <20220607192350.znejys3gs4kakjw7@marcos.localdomain> <CAH+w=7bzCH5jzVszH9wb0qfA+PhhVwUuJTOMUJXuE0eQJJQ+=g@mail.gmail.com>
On Jun 07 10:02PM, Bart Schaefer wrote:
On Tue, Jun 7, 2022 at 12:24 PM Adam Cooper <adam@xxxxxxxxxxxxxxxxx> wrote:
After installing xmonad on an Arch Linux system, my zsh history has begun to misbehave. HISTFILE is read from .zshenv after logging into the console, but once I start xmonad and a terminal, HISTFILE is empty.
[...]
Here is a link to my .zshenv: https://git.theadamcooper.com/adam/dotfiles/src/branch/master/arch/zsh/.zshenv
Well, there's this:
export ZDOTDIR="$XDG_CONFIG_HOME/zsh"
Once that's in the environment, $HOME/.zshenv isn't going to be read
any more, rather, the dot-files in $ZDOTDIR are going to be read
instead ... so you should look there.
My reading of the docs tells me that (in the absence of /etc/zsh/zshenv) ~/.zshenv is read first, and if ZDOTDIR is set there, the remaining configuration files will be read from ZDOTDIR. (Moving .zshenv into ZDOTDIR resulted in zsh displaying a menu with options for configuring zsh from the start.)
Evidence-wise, when I first log in to tty1, HISTFILE is set, as is HISTSIZE (conspicuously set to 9998), so I conclude .zshenv is being read. When I then run startx to enter xmonad, HISTFILE is unset, while HISTSIZE remains set. The only other configuration file, ZDOTDIR/.zshrc, is read correctly.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author