Esse é apenas o valor padrão para HISTFILE .
When the shell starts up, the history is initialized from the file named by the
HISTFILEvariable (default~/.bash_history).
Parece que você substituiu seu PROMPT_COMMAND . Você pode querer recuperar o comportamento normal adicionando shell_session_history_check; ao início dele. Adicione echo $PROMPT_COMMAND ao topo do seu perfil para ver o valor padrão para ele ( shell_session_history_check; terminal_update_cwd ).
Depois de fazer isso, HISTFILE será sobrescrito nessa função (execute declare -f shell_session_history_check para ver a chamada de função para shell_session_history_enable ):
$ declare -f shell_session_history_enable
shell_session_history_enable ()
{
( umask 077;
/usr/bin/touch "$SHELL_SESSION_HISTFILE_NEW" );
HISTFILE="$SHELL_SESSION_HISTFILE_NEW";
SHELL_SESSION_HISTORY=1
}
Isso criará um arquivo em .bash_sessions para armazenar um log de cada sessão separadamente. Mais sobre Reddit :
(~/.bash_sessions/) is used to store HISTFILE's and .session files that are unique to sessions. If $BASH_SESSION or $TERM_SESSION_ID is set upon launching the shell (i.e. if Terminal is resuming from a saved state), the associated HISTFILE is merged into the current one, and the .session file is ran. Session saving is facilitated by means of an EXIT trap being set for a function bash_update_session_state.