From d0a37b9ec38377c263ce3eb33c726abb06e2fbc3 Mon Sep 17 00:00:00 2001 From: Yax <1949284+kianby@users.noreply.github.com> Date: Thu, 3 Nov 2022 19:19:46 +0100 Subject: [PATCH] enable history at the end --- dot_bashrc | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/dot_bashrc b/dot_bashrc index 402db76..6e2184d 100644 --- a/dot_bashrc +++ b/dot_bashrc @@ -9,6 +9,9 @@ [[ -z "$FUNCNEST" ]] && export FUNCNEST=100 # limits recursive functions, see 'man bash' +# disable history +HISTFILE=/dev/null + ## Use the up and down arrow keys for finding a command in history ## (you can write some initial letters of the command first). bind '"\e[A":history-search-backward' @@ -137,8 +140,6 @@ fi # --------------------------------------------------------------------------- # History # --------------------------------------------------------------------------- -set -o history -#unset HISTFILE # don't put duplicate lines or lines starting with space in the history. # See bash(1) for more options @@ -159,3 +160,8 @@ HISTIGNORE=history* # merge history b/w sessions PROMPT_COMMAND="history -a; history -c; history -r; $PROMPT_COMMAND" + +HISTFILE=~/.bash_history + +# enable history +set -o history