From 1272a398005c9f6c43e1567078a708fd500624d2 Mon Sep 17 00:00:00 2001 From: Koichi Murase Date: Thu, 23 Jun 2022 11:03:11 +0900 Subject: [PATCH] lib/history: Remove the limit of the history sizes --- lib/history.sh | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/lib/history.sh b/lib/history.sh index ff29622..18f6b56 100644 --- a/lib/history.sh +++ b/lib/history.sh @@ -16,10 +16,10 @@ shopt -s histappend # Save multi-line commands as one command shopt -s cmdhist -# use readline on history +# Re-edit the command line for failing history expansions shopt -s histreedit -# load history line onto readline buffer for editing +# Re-edit the result of history expansions shopt -s histverify # save history with newlines instead of ; where possible @@ -28,9 +28,10 @@ shopt -s lithist # Record each line as it gets issued _omb_util_add_prompt_command 'history -a' -# Huge history. Doesn't appear to slow things down, so why not? -HISTSIZE=500000 -HISTFILESIZE=100000 +# Unlimited history size. Doesn't appear to slow things down, so why not? +# Export these variables to apply them also to the child shell sessions. +export HISTSIZE= +export HISTFILESIZE= # Avoid duplicate entries HISTCONTROL="erasedups:ignoreboth"