codehia
codehia

Reputation: 184

The key bind I had set up in zshrc is not working in tmux session

I had set up a key binding for accepting autosuggest suggestions, bindkey '^ ' autosuggest-accept, which works in without tmux activated, however once in tmux this doesn't work anymore.

I suspect it might have something to do with set -g terminal-overrides "$TERM:RGB" in the tmux conf.

Any help will be appreciated.

Upvotes: 0

Views: 1024

Answers (1)

codehia
codehia

Reputation: 184

The keybind should be palced after sourcing source $ZSH/oh-my-zsh.sh for it to be used in the tmux.

export TERM=tmux-256color
source $ZSH/oh-my-zsh.sh
bindkey '^ ' autosuggest-accept
eval "$(starship init zsh)"

Hope this helps anyone facing the same issue.

Upvotes: 3

Related Questions