tmux: add resurrect to save/restore pane/window layout
This commit is contained in:
parent
e1160acbe1
commit
2f2a9657c2
47 changed files with 2579 additions and 0 deletions
23
.config/tmux/plugins/resurrect/strategies/irb_default_strategy.sh
Executable file
23
.config/tmux/plugins/resurrect/strategies/irb_default_strategy.sh
Executable file
|
|
@ -0,0 +1,23 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
# "irb default strategy"
|
||||
#
|
||||
# Example irb process with junk variables:
|
||||
# irb RBENV_VERSION=1.9.3-p429 GREP_COLOR=34;47 TERM_PROGRAM=Apple_Terminal
|
||||
#
|
||||
# When executed, the above will fail. This strategy handles that.
|
||||
|
||||
ORIGINAL_COMMAND="$1"
|
||||
DIRECTORY="$2"
|
||||
|
||||
original_command_wo_junk_vars() {
|
||||
echo "$ORIGINAL_COMMAND" |
|
||||
sed 's/RBENV_VERSION[^ ]*//' |
|
||||
sed 's/GREP_COLOR[^ ]*//' |
|
||||
sed 's/TERM_PROGRAM[^ ]*//'
|
||||
}
|
||||
|
||||
main() {
|
||||
echo "$(original_command_wo_junk_vars)"
|
||||
}
|
||||
main
|
||||
Loading…
Add table
Add a link
Reference in a new issue