0

I want to remap my F9 key to the dollar sign ($) symbol.

So I ran this command

bind '"\e[20": "$"'

Now whenever I type the F9 key, instead of getting just

$

I get

$~

Why is the extra tilde there and how can I get rid of it?

  • F9 is \e[20~ for me. That's probably where the ~ comes from. Press Ctrl-V and then F9. What do you get? – muru Dec 15 '16 at 09:00

1 Answers1

1

Try this:

bind '"\e[20~": "$"'

To determine character sequence for a key press,

  • Press Ctrl+v and press the key for which you want to get the character sequence.

Example:

For key F9, I get ^[[20~ where ^[ is Esc key and remaining sequence is for F9.

Thushi
  • 9,498