This change seems to do what you want. It passes ! and \ untouched, it gets history from the shell and it uses the zsh line editor for arrow keys and home/end.
This change seems to do what you want. It passes ! and \ untouched, it gets history from the shell and it uses the zsh line editor for arrow keys and home/end.