mirror of
https://github.com/tmux-plugins/tmux-resurrect.git
synced 2024-11-25 06:18:48 +00:00
Improve active/alternate window restoring
This commit is contained in:
parent
8051fb9d36
commit
4d5c0a2a0d
@ -120,7 +120,7 @@ restore_active_pane_for_each_window() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
restore_active_and_alternate_windows() {
|
restore_active_and_alternate_windows() {
|
||||||
awk 'BEGIN { FS="\t"; OFS="\t" } /^pane/ && $6 ~ /[*-]/ { print $2, $5, $3; }' $(last_session_path) |
|
awk 'BEGIN { FS="\t"; OFS="\t" } /^window/ && $5 ~ /[*-]/ { print $2, $4, $3; }' $(last_session_path) |
|
||||||
sort -u |
|
sort -u |
|
||||||
while IFS=$'\t' read session_name active_window window_number; do
|
while IFS=$'\t' read session_name active_window window_number; do
|
||||||
tmux switch-client -t "${session_name}:${window_number}"
|
tmux switch-client -t "${session_name}:${window_number}"
|
||||||
|
Loading…
Reference in New Issue
Block a user