From 9f23de9cbaad30ef92c75a4e9dcf626794e390cf Mon Sep 17 00:00:00 2001 From: 10sr <8.slashes@gmail.com> Date: Tue, 3 Mar 2020 17:39:03 +0900 Subject: [PATCH] Enable histappend --- shrc | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/shrc b/shrc index 86cdd2f..a24d1ea 100755 --- a/shrc +++ b/shrc @@ -131,6 +131,15 @@ then # stty erase '^h' fi +if $inbash +then + # https://unix.stackexchange.com/questions/1288/preserve-bash-history-in-multiple-terminal-windows + # Avoid duplicates + HISTCONTROL=ignoredups:erasedups + # When the shell exits, append to the history file instead of overwriting it + shopt -s histappend +fi + # Zsh specific preferences # http://www.clear-code.com/blog/2011/9/5.html if $inzsh