aboutsummaryrefslogtreecommitdiff
path: root/bash/bashrc
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2016-08-18 15:45:51 +1200
committerTom Ryder <tom@sanctum.geek.nz>2016-08-18 15:47:36 +1200
commite6cae908d07ef35374919883c9aa868fb86600cc (patch)
tree00dd71acf7d9e4150e8d694fb2475e1653ac5fac /bash/bashrc
parentSuppress stderr from command -v checks (diff)
downloaddotfiles-e6cae908d07ef35374919883c9aa868fb86600cc.tar.gz
dotfiles-e6cae908d07ef35374919883c9aa868fb86600cc.zip
Drastically limit amount of history kept
Reading really large files seems to be slow in Bash in general, but it's particularly bad in 4.4rc1. I keep encrypted snapshots of my HISTFILE on my home machine, so it's just a little extra step to search them.
Diffstat (limited to 'bash/bashrc')
-rw-r--r--bash/bashrc8
1 files changed, 4 insertions, 4 deletions
diff --git a/bash/bashrc b/bash/bashrc
index 220ecec6..7defd85d 100644
--- a/bash/bashrc
+++ b/bash/bashrc
@@ -19,11 +19,11 @@ if shopt -q restricted_shell ; then
return
fi
-# Keep around sixteen million lines of history in file
-HISTFILESIZE=$((1 << 24))
+# Keep around four thousand lines of history in file
+HISTFILESIZE=$((1 << 12))
-# Keep around four thousand lines of history in memory
-HISTSIZE=$((1 << 12))
+# Keep around one thousand lines of history in memory
+HISTSIZE=$((1 << 10))
# Ignore duplicate commands and whitespace in history
HISTCONTROL=ignoreboth