4 ms·
I switched a year or two ago It wasn't until I switched that I realized how poor bash and zsh are in comparison, even with fzf 10 min install, never looked ba
by jeppesen-io 3y ago
I switched a year or two ago
It wasn't until I switched that I realized how poor bash and zsh are in comparison, even with fzf
10 min install, never looked back
Not to mention the safety. Never could figure it out, but once every 15 months or so, zsh would disappear my history. Certainly a mistake on my end, but still too easy to blow away history
- zimbu668 3y agoI would occasionally manage to start a bash shell without executing my profile, which means HISTFILESIZE is not set and bash would truncate my history on the first command I ran. zsh history may have a similar problem.
- eviks 3y agoYes, bad defaults strike again!
- meribold 3y agoI think that's it! I've been wondering why Bash sometimes deletes most of my history for ages. My .bashrc sets up an EXIT trap that git-commits my history, so I just looked at the commits that remove lines and found that 7 out of 8 of those commits change the size of the history file to about 1000 lines. Since my history file contains timestamps, that matches the 500-command default of HISTSIZE, so the truncation mechanism you described seems to be what's happening. A few days ago I actually made my history file append-only to prevent truncation.
- meribold 3y agoSetting HISTFILE to a non-default value in the same place as HISTSIZE/HISTFILESIZE seems like it would solve this problem nicely.
- joobus 3y agoThis is exactly why I'm considering using atuin also. My zsh history on my mac will sometimes just completely disappear and then I have to go lookup what I was trying to do again. It is driving me crazy.
- alchemist1e9 3y agoThis happens to me also!! Does anybody know why? I ignore it as macos is a secondary and less critical environment for me but it’s really annoying.