I often open lots and lots of terminals (right now, I have seven open on this workspace) and I often search
grep to find a command I've just written recently, but I don't want to hunt down the terminal and then scroll up and hunt for it.
Sometimes my terminals close without
exit, and everything I've written in them is lost. Sometimes, I needed something I'd written in a terminal that was killed.
Is there a way to make it so that each terminal writes to
.bash_history immediately? Or at least once a minute, or something like that?