EDIT: Partial solution for now is to call exec zsh in my bashrc and call it a day. I don’t like it but history behaves normally at least.
I have been trying to fix this for ages.
Adding HISTCONTROL=ignoredups or HISTCONTROL=erasedups does not work as pressing the Up arrow key goes to last environment variable in my bashrc. My bash_history duplicates bashrc for every shell I open. It has been a few months since I actually used my history.
The first few lines of my bashrc are as follows:
set -o history export HISTFILE=~/.bash_history export HISTCONTROL=ignoredups export HISTSIZE=100000 export SAVEHIST=100000
I had copied over the .histfile when I was using zsh. Zsh broke for me a while back, wouldn’t let me log in or use anythin in /bin so I reverted to Bash but the history is still messed up. I can still ctrl-R and find commands, but it’s suboptimal, I heavily rely on History to get any work done. Any help would be awessome! Thanks!