X-Git-Url: https://git.immae.eu/?p=perso%2FImmae%2FConfig%2FAnsible.git;a=blobdiff_plain;f=roles%2Fshell%2Fbash%2Ftemplates%2Fbashrc.j2;h=fabe53fb5ec63f80d0a0529f23a2e1b8bb8ac9fd;hp=91334b735225dc28871d9604e50295011dda5901;hb=bfe7d9cb1f547161cb7c7f4924c62c6ef819e4d7;hpb=86a3ca82c74c9109594b4d7c4a61f2d804b8ccc0 diff --git a/roles/shell/bash/templates/bashrc.j2 b/roles/shell/bash/templates/bashrc.j2 index 91334b7..fabe53f 100644 --- a/roles/shell/bash/templates/bashrc.j2 +++ b/roles/shell/bash/templates/bashrc.j2 @@ -90,6 +90,11 @@ _tmux_dev() { done } complete -o filenames -F _tmux_dev tmux_dev + +if [ -n "$TMUX" ]; then + TMUX_SESSION_NAME=$(tmux display-message -p "#S") + export HISTFILE="$XDG_STATE_HOME/bash/tmux_${TMUX_SESSION_NAME}_history" +fi ##### /Fretlink {% endif %}