diff options
| author | Kyle Gerard Felker <felker@anl.gov> | 2021-01-07 23:58:02 -0600 |
|---|---|---|
| committer | jixiuf <jixiuf@qq.com> | 2021-02-07 11:55:15 +0800 |
| commit | 09cf48de5eb4db7520611bb55440141c15f18001 (patch) | |
| tree | 92962ea358ee3c675c3543d6f2f32e330478a863 /README.md | |
| parent | b6592f94d76098d19f242c0d09f660f6a6461b76 (diff) | |
Fix vterm_printf tmux escape sequence pass through
Such that it is not activated if Emacs and vterm are running within a
tmux session.
The passthrough still functions for running tmux within Emacs and vterm
Diffstat (limited to 'README.md')
| -rw-r--r-- | README.md | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -242,7 +242,7 @@ readme. For `bash` or `zsh`, put this in your `.zshrc` or `.bashrc` ```bash vterm_printf(){ - if [ -n "$TMUX" ]; then + if [ -n "$TMUX" ] && ([ "${TERM%%-*}" = "tmux" ] || [ "${TERM%%-*}" = "screen" ] ); then # Tell tmux to pass the escape sequences through printf "\ePtmux;\e\e]%s\007\e\\" "$1" elif [ "${TERM%%-*}" = "screen" ]; then @@ -258,7 +258,7 @@ This works also for `dash`. For `fish` put this in your `~/.config/fish/config.fish`: ```bash function vterm_printf; - if [ -n "$TMUX" ] + if begin; [ -n "$TMUX" ] ; and string match -q -r "screen|tmux" "$TERM"; end # tell tmux to pass the escape sequences through printf "\ePtmux;\e\e]%s\007\e\\" "$argv" else if string match -q -- "screen*" "$TERM" |
