update shell history path

py is less convenient accessing inodes than pwsh, no need to redirect.
This commit is contained in:
2025-12-31 20:51:18 +08:00
parent 4cb055fac4
commit 6e2299e23f
2 changed files with 4 additions and 4 deletions

View File

@@ -1,6 +1,6 @@
# init at each startup
mkdir -p /tmp/$USER/PSReadLine
#ln -sf /tmp/$USER $HOME/.tmp
# to clear history of shells easily operating filesystem.
# also powershell/PSReadLine -> /tmp/$USER/terminal
mkdir -p /tmp/$USER/terminal
# avoid dumplicate env appending.
# [[ -f /run/user/$UID/.zshlogon ]] && return

2
.zshrc
View File

@@ -20,7 +20,7 @@ fi
#
# also export this in bashrc.
HISTFILE=/tmp/$USER/.zhist
HISTFILE=/tmp/$USER/terminal/zsh_history
# Remove older command from the history if a duplicate is to be added.
setopt HIST_IGNORE_ALL_DUPS