mirror of
https://github.com/tmux-plugins/tmux-resurrect.git
synced 2024-11-21 20:08:48 +00:00
try to treat inline strategy as alias for strategy
if strategy with that name exists apply it otherwise use it as inline strategy Closes #88
This commit is contained in:
parent
8af7aed9b3
commit
ed6fb9b523
@ -20,6 +20,11 @@ restore_pane_process() {
|
||||
local inline_strategy="$(_get_inline_strategy "$pane_full_command")" # might not be defined
|
||||
if [ -n "$inline_strategy" ]; then
|
||||
# inline strategy exists
|
||||
# check for additional "expansion" of inline strategy, e.g. `vim` to `vim -S`
|
||||
if _strategy_exists "$inline_strategy"; then
|
||||
local strategy_file="$(_get_strategy_file "$inline_strategy")"
|
||||
local inline_strategy="$($strategy_file "$pane_full_command" "$dir")"
|
||||
fi
|
||||
tmux send-keys "$inline_strategy" "C-m"
|
||||
elif _strategy_exists "$pane_full_command"; then
|
||||
local strategy_file="$(_get_strategy_file "$pane_full_command")"
|
||||
|
Loading…
Reference in New Issue
Block a user