mirror of
https://github.com/tmux-plugins/tmux-resurrect.git
synced 2025-09-10 21:23:09 +00:00
Compare commits
6 Commits
Author | SHA1 | Date | |
---|---|---|---|
95303946b2 | |||
1d09f07d2b | |||
618769b62f | |||
fac377bf8c | |||
dc7561df74 | |||
eb2cd31d4b |
@ -2,6 +2,9 @@
|
|||||||
|
|
||||||
### master
|
### master
|
||||||
|
|
||||||
|
### v1.3.0, 2014-09-20
|
||||||
|
- remove dependency on `pgrep` command. Use `ps` for fetching process names.
|
||||||
|
|
||||||
### v1.2.1, 2014-09-02
|
### v1.2.1, 2014-09-02
|
||||||
- tweak 'new_pane' creation strategy to fix #36
|
- tweak 'new_pane' creation strategy to fix #36
|
||||||
- when running multiple tmux server and for a large number of panes (120 +) when
|
- when running multiple tmux server and for a large number of panes (120 +) when
|
||||||
|
12
README.md
12
README.md
@ -27,8 +27,8 @@ Some people can't get `Alt` key mappings to work so they are deprecated.
|
|||||||
|
|
||||||
For custom key bindings, add to `.tmux.conf`:
|
For custom key bindings, add to `.tmux.conf`:
|
||||||
|
|
||||||
set -g @resurrect-save "S"
|
set -g @resurrect-save 'S'
|
||||||
set -g @resurrect-restore "R"
|
set -g @resurrect-restore 'R'
|
||||||
|
|
||||||
### About
|
### About
|
||||||
|
|
||||||
@ -47,7 +47,10 @@ This plugin goes to great lengths to save and restore all the details from your
|
|||||||
- restoring vim sessions (optional). More details in
|
- restoring vim sessions (optional). More details in
|
||||||
[restoring vim sessions](#restoring-vim-sessions).
|
[restoring vim sessions](#restoring-vim-sessions).
|
||||||
|
|
||||||
Requirements / dependencies: `tmux 1.9` or higher, `pgrep`
|
Requirements / dependencies: `tmux 1.9` or higher, `bash`.
|
||||||
|
|
||||||
|
`tmux-resurrect` is idempotent! It will not try to restore panes or windows that
|
||||||
|
already exist.
|
||||||
|
|
||||||
### Installation with [Tmux Plugin Manager](https://github.com/tmux-plugins/tpm) (recommended)
|
### Installation with [Tmux Plugin Manager](https://github.com/tmux-plugins/tpm) (recommended)
|
||||||
|
|
||||||
@ -84,7 +87,6 @@ Configuration is not required, but it enables extra features.
|
|||||||
|
|
||||||
Only a conservative list of programs is restored by default:<br/>
|
Only a conservative list of programs is restored by default:<br/>
|
||||||
`vi vim emacs man less more tail top htop irssi`.
|
`vi vim emacs man less more tail top htop irssi`.
|
||||||
Open a GitHub issue if you think some other program should be on the default list.
|
|
||||||
|
|
||||||
- Restore additional programs with the setting in `.tmux.conf`:
|
- Restore additional programs with the setting in `.tmux.conf`:
|
||||||
|
|
||||||
@ -116,7 +118,7 @@ Open a GitHub issue if you think some other program should be on the default lis
|
|||||||
- save vim sessions. I recommend [tpope/vim-obsession](https://github.com/tpope/vim-obsession).
|
- save vim sessions. I recommend [tpope/vim-obsession](https://github.com/tpope/vim-obsession).
|
||||||
- in `.tmux.conf`:
|
- in `.tmux.conf`:
|
||||||
|
|
||||||
set -g @resurrect-strategy-vim "session"
|
set -g @resurrect-strategy-vim 'session'
|
||||||
|
|
||||||
`tmux-resurrect` will now restore vim sessions if `Sessions.vim` file is
|
`tmux-resurrect` will now restore vim sessions if `Sessions.vim` file is
|
||||||
present.
|
present.
|
||||||
|
@ -66,8 +66,9 @@ dump_panes_raw() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
pane_full_command() {
|
pane_full_command() {
|
||||||
pane_pid="$1"
|
local pane_pid="$1"
|
||||||
\pgrep -lf -P "$pane_pid" |
|
ps -eo "ppid command" |
|
||||||
|
grep "^${pane_pid}" |
|
||||||
cut -d' ' -f2-
|
cut -d' ' -f2-
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user