Zsh-autosuggestions: bindkey ctrl-return?

Created on 3 May 2016  路  3Comments  路  Source: zsh-users/zsh-autosuggestions

I would like to have ctrl-return mapped to autosuggest-execute

I have tried bindkey with ^enter'' ,^^M`` etc but none of them works.

Is there a way to do so?

Thanks,

Most helpful comment

In case anyone is having the same problem, just use cat without arguments to find out which escape sequence your terminal is emitting for ctrl-enter:

> cat
^[[28;5;9~

Then bind it like this bindkey -s '^[[28;5;9~' '^E\n' in your ~/.zshrc. bindkey '^[[28;5;9~' autosuggest-execute might also work, depending on your configuration.

All 3 comments

I'm personally not sure if this is possible with zsh.

You might have some luck emailing the zsh-users email list: http://zsh.sourceforge.net/Arc/mlist.html

I'm going to go ahead and close this issue since it doesn't relate specifically to the plugin.

Good luck!

In case anyone is having the same problem, just use cat without arguments to find out which escape sequence your terminal is emitting for ctrl-enter:

> cat
^[[28;5;9~

Then bind it like this bindkey -s '^[[28;5;9~' '^E\n' in your ~/.zshrc. bindkey '^[[28;5;9~' autosuggest-execute might also work, depending on your configuration.

This did the trick for me:

bindkey '^\n' autosuggest-execute
Was this page helpful?
0 / 5 - 0 ratings

Related issues

raulferras picture raulferras  路  3Comments

mindyourlifeguide picture mindyourlifeguide  路  6Comments

guitaristtom picture guitaristtom  路  6Comments

silverneko picture silverneko  路  5Comments

glacambre picture glacambre  路  3Comments