Fix bash history not being recreated

pull/1/head
sundowndev 2019-01-08 15:08:57 +01:00
parent 967bc6006e
commit 3e3752bd2f
1 changed files with 6 additions and 3 deletions

View File

@ -69,13 +69,14 @@ elif [[ $option == 2 ]]; then
elif [[ $option == 3 ]]; then elif [[ $option == 3 ]]; then
# Restore default settings # Restore default settings
if [[ -L ~/.bash_history ]]; then if [[ -L ~/.bash_history ]]; then
rm ~/.bash_history -rf rm -rf ~/.bash_history
echo "" > ~/.bash_history
echo "[+] Disabled sending history to /dev/null" echo "[+] Disabled sending history to /dev/null"
fi fi
echo "" > ~/.bash_history
if [[ -L ~/.zsh_history ]]; then if [[ -L ~/.zsh_history ]]; then
rm ~/.zsh_history -rf rm -rf ~/.zsh_history
echo "" > ~/.zsh_history echo "" > ~/.zsh_history
echo "[+] Disabled sending zsh history to /dev/null" echo "[+] Disabled sending zsh history to /dev/null"
fi fi
@ -84,6 +85,8 @@ elif [[ $option == 3 ]]; then
export HISTSIZE=50000 export HISTSIZE=50000
echo "[+] Restore HISTFILESIZE & HISTSIZE default values" echo "[+] Restore HISTFILESIZE & HISTSIZE default values"
# set +o history # Undo this
echo echo
echo "Permenently enabled bash log." echo "Permenently enabled bash log."
elif [[ $option == 99 ]]; then elif [[ $option == 99 ]]; then