4 ms·
I set HISTFILE=~/.bash_history_$TMUX_PANE (when that variable is set). A bit kludgy, but works good enough for me.
by livrem 3y ago
I set HISTFILE=~/.bash_history_$TMUX_PANE (when that variable is set).
A bit kludgy, but works good enough for me.
- severino 3y agoYes, but if one process is writing its history to ~/.bash_history_1, and some time later you spawn a new shell whose history file points to ~/.bash_history_2, you won't have the commands from the previous session available, right?
- livrem 3y agoCorrect, but most of the time I use the same set of panes, created at startup, so the commands are in the history where I need them. And when they are not I grep in ~/.bash_history_*.