iTerm shell integration

Important – iTerm shell integration

  1. Shell integration should be installed on all remote hosts
  2. Connections to non standard ssh port (other than 22) can be setup in ~/.ssh/config. Format below
Host www.adhocshare.tk
    HostName 192.168.80.200
    Port 10527

 

Iterm2 bash prompt mess up

Iterm2 shell integration will mess up with your bash prompt with weird looking characters. To fix that find below line in your .bashrc/ .bash_profile

test -r ~/.iterm2_shell_integration.bash && . ~/.iterm2_shell_integration.bash

and change it to

[[ $TERM_PROGRAM == "iTerm.app" ]] && test -r ~/.iterm2_shell_integration.bash && . ~/.iterm2_shell_integration.bash

 

References:

https://gitlab.com/gnachman/iterm2/wikis/scp-not-connecting
https://iterm2.com/documentation-shell-integration.html
https://unix.stackexchange.com/questions/292042/how-to-fix-shell-prompt-ps1-odd-escape-sequences-after-remote-login-from-ite

 

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *