Update bash dotfiles (history)

This commit is contained in:
Santiago Lo Coco 2025-02-01 16:37:40 +01:00
parent 8fab74d69f
commit 39753fbb1b
Signed by: slococo
GPG Key ID: F995EFC8B68B1ADF
2 changed files with 14 additions and 4 deletions

View File

@ -60,6 +60,20 @@ export XINITRC="$XDG_CONFIG_HOME"/X11/xinitrc
export PATH="$HOME/.local/bin:$PATH" export PATH="$HOME/.local/bin:$PATH"
export HISTFILE="$XDG_STATE_HOME"/bash/history
export HISTSIZE=10000000
export HISTFILESIZE=10000000
export HISTCONTROL=erasedups:ignoreboth
#export HISTTIMEFORMAT="%s;"
# shopt -s histappend
#original_prompt_command=${original_prompt_command-$PROMPT_COMMAND}
#PROMPT_COMMAND="history -a; history -n; $original_prompt_command"
#PROMPT_COMMAND="history -a; $PROMPT_COMMAND"
#PROMPT_COMMAND="history -w; history -a; $PROMPT_COMMAND"
export PROMPT_COMMAND="history -a; $PROMPT_COMMAND"
if grep -q "i5" /proc/cpuinfo; then if grep -q "i5" /proc/cpuinfo; then
export LAPTOP="" export LAPTOP=""
fi fi

View File

@ -1,9 +1,5 @@
#!/bin/sh #!/bin/sh
export HISTFILE="$XDG_STATE_HOME"/bash/history
export HISTSIZE=10000000
export HISTFILESIZE=10000000
if [ -f "${XDG_CONFIG_HOME:-$HOME/.config}/shell/aliasrc" ]; then if [ -f "${XDG_CONFIG_HOME:-$HOME/.config}/shell/aliasrc" ]; then
source "${XDG_CONFIG_HOME:-$HOME/.config}/shell/aliasrc" source "${XDG_CONFIG_HOME:-$HOME/.config}/shell/aliasrc"
fi fi