diff --git a/_home/dot_sz.shrc.d/bash.post/11_persistent.history b/_home/dot_sz.shrc.d/bash.post/11_persistent.history index 0a5fcde..bce26ab 100644 --- a/_home/dot_sz.shrc.d/bash.post/11_persistent.history +++ b/_home/dot_sz.shrc.d/bash.post/11_persistent.history @@ -4,4 +4,6 @@ export HISTFILESIZE=100000 # big big history shopt -s histappend # append to history, don't overwrite it # Save and reload the history after each command finishes -export PROMPT_COMMAND="history -a; history -c; history -r; $PROMPT_COMMAND" +if ! [[ "$PROMPT_COMMAND" =~ "history -a; history -c; history -r;" ]]; then + export PROMPT_COMMAND="history -a; history -c; history -r; $PROMPT_COMMAND" +fi