mirror of
https://github.com/tmux-plugins/tmux-resurrect.git
synced 2024-11-14 00:08:49 +00:00
feat: append socket path to resurrect_dir
BREAKING: will break existing sessions, since session save location is changed. Supposed migration path (to be tested): while Tmux is running, remove previous version of resurrect (remove from Tmux conf & TPM uninstall), then install this version, then save your session.
This commit is contained in:
parent
cff343cf9e
commit
4e1cdfa169
@ -98,7 +98,7 @@ pane_content_files_restore_from_archive() {
|
||||
|
||||
resurrect_dir() {
|
||||
if [ -z "$_RESURRECT_DIR" ]; then
|
||||
local path="$(get_tmux_option "$resurrect_dir_option" "$default_resurrect_dir")"
|
||||
local path="$(get_tmux_option "$resurrect_dir_option" "$default_resurrect_dir")/$(basename $(tmux display-message -p -F "#{socket_path}"))"
|
||||
# expands tilde, $HOME and $HOSTNAME if used in @resurrect-dir
|
||||
echo "$path" | sed "s,\$HOME,$HOME,g; s,\$HOSTNAME,$(hostname),g; s,\~,$HOME,g"
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user