tmux: add resurrect + continuum so force-quits don't nuke sessions
Twice in the last few sessions a Love2D force-quit cascaded into killing the tmux server and losing every window. Resurrect snapshots windows / panes / cwd / pane contents (with capture-pane-contents on) to ~/.local/share/tmux/resurrect/last. Continuum auto-saves every 15 min and auto-restores on tmux server start — so the next force-quit just costs up to 15 min of recent activity, not the whole workspace. Manual save: prefix + Ctrl-s. Manual restore: prefix + Ctrl-r. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
b2df891b20
commit
ba51b6bcf7
1 changed files with 22 additions and 0 deletions
|
|
@ -88,6 +88,28 @@
|
|||
catppuccin
|
||||
tmux-fzf
|
||||
extrakto
|
||||
# tmux-resurrect: prefix + Ctrl-s saves, prefix + Ctrl-r restores.
|
||||
# Snapshot lives at ~/.local/share/tmux/resurrect/last (window
|
||||
# layout, working dirs, pane contents if enabled). Survives
|
||||
# force-quits / reboots / kernel panics.
|
||||
{
|
||||
plugin = resurrect;
|
||||
extraConfig = ''
|
||||
set -g @resurrect-capture-pane-contents 'on'
|
||||
set -g @resurrect-strategy-nvim 'session'
|
||||
'';
|
||||
}
|
||||
# tmux-continuum: auto-saves every 15min and auto-restores on
|
||||
# tmux server start. With this, the next force-quit just costs
|
||||
# you up to 15min of recent terminal activity, not the whole
|
||||
# workspace.
|
||||
{
|
||||
plugin = continuum;
|
||||
extraConfig = ''
|
||||
set -g @continuum-restore 'on'
|
||||
set -g @continuum-save-interval '15'
|
||||
'';
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue