map alt+delete in git-bash inputrc

Does anyone know how to bind key combinations with Alt in inputrc in git-bash?

I want to map a key combination Alt+delete to kill-word, but when I press Ctrl+V and Alt+delete to see what characters it represents, it simply shows ^[, which is wrong.

I know that in order to bind Ctrl+Left Arrow to something I can press Ctrl+V, which will type ^[[1;5D and then replace ^[ with \e and finally write add this line to .inputrc:

"\e[1;5D": forward-word

But this method doesn't work for me with Alt+(literally anything).

This answer works on Ubuntu, but stty raw doesn't work in git-bash apparently.

Reset to default

Know someone who can answer? Share a link to this question via email, Twitter, or Facebook.

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

You Might Also Like