WindTerm icon indicating copy to clipboard operation
WindTerm copied to clipboard

Doesn't hide ESC]1337;

Open tianshuo opened this issue 2 years ago • 2 comments

These messages are shown by iterm2 integration, yet they are displayed in WindTerm. They should be hidden

ESC]1337;RemoteHost=remoteserverESC]1337;CurrentDir=/root root@remoteserver:~$

tianshuo avatar Aug 11 '22 03:08 tianshuo

year i have too

zzkkoo8 avatar Aug 19 '22 03:08 zzkkoo8

ESC]1337;[email protected]]1337;CurrentDir=/root/sitkupdate[root@localhost sitkupdate]#

Comment out the following two lines in remote host .bash_profile #export iterm2_hostname=172.16.90.56 #test -e "${HOME}/.iterm2_shell_integration.bash" && source "${HOME}/.iterm2_shell_integration.bash"

cnsitk avatar Aug 30 '22 07:08 cnsitk

ESC]1337;RemoteHost=[email protected]]1337;CurrentDir=/root/sitkupdate[root@localhost sitkupdate]#

Comment out the following two lines in remote host .bash_profile #export iterm2_hostname=172.16.90.56 #test -e "${HOME}/.iterm2_shell_integration.bash" && source "${HOME}/.iterm2_shell_integration.bash"

it works

PaSSw0rds avatar Oct 19 '22 06:10 PaSSw0rds

ESC]1337;RemoteHost=[email protected]]1337;CurrentDir=/root/sitkupdate[root@localhost sitkupdate]#

Comment out the following two lines in remote host .bash_profile #export iterm2_hostname=172.16.90.56 #test -e "${HOME}/.iterm2_shell_integration.bash" && source "${HOME}/.iterm2_shell_integration.bash"

有效的。具体我做的办法: 原因是 ~/.bash_profile 文件多了一些内容

# .bash_profile

# Get the aliases and functions
if [ -f ~/.bashrc ]; then
        . ~/.bashrc
fi

# User specific environment and startup programs

PATH=$PATH:$HOME/.local/bin:$HOME/bin

export PATH
export PS1="$PS1\[\e]1337;CurrentDir="'$(pwd)\a\]'

是多了最后一行导致了每个命令结束都会打印额外的信息。

修改 ~/.bash_profile 文件为

# .bash_profile

# Get the aliases and functions
if [ -f ~/.bashrc ]; then
        . ~/.bashrc
fi

# User specific environment and startup programs

PATH=$PATH:$HOME/.local/bin:$HOME/bin

export PATH

leehow1988 avatar May 31 '23 02:05 leehow1988