DEV Community

Mikko Matilainen
Mikko Matilainen

Posted on

3 2

VSCode terminal & meta key

I had the same issue as described here: https://superuser.com/questions/1549993/how-to-map-option-shift-digit-keys-in-zsh-using-bindkey

I went with the same solution that disables terminal.integrated.macOptionIsMeta and uses bindkey to map the traditional readline meta key commands. I added insert-last-word and had to modify the bound characters to some extent. Still need to figure out how to best handle dead keys (option-t and option-u for example)...

bindkey '' accept-and-hold # option-a
bindkey 'ƒ' forward-word # option-b
bindkey 'ç' fzf-cd-widget # option-c
bindkey 'ð' delete-word # option-d
bindkey '›' backward-word # option-f
bindkey '¸' get-line # option-g
bindkey '˛' run-help # option-h
bindkey 'fi' down-case-word # option-l
bindkey '‘' history-search-forward # option-n
bindkey 'π' history-search-backward # option-p
bindkey '•' push-line # option-q
bindkey 'ß' spell-word # option-s
bindkey '†' transpose-words # option-t
bindkey 'ˀ' up-case-word # option-u
bindkey 'Ω' copy-region-as-kill # option-w
bindkey '≈' execute-named-cmd # option-x
bindkey 'µ' yank-pop # option-y
bindkey '…' insert-last-word # option-.
Enter fullscreen mode Exit fullscreen mode

Would be nice if VSCode supported choosing just the left option key as meta, same as iTerm does.

Image of Docusign

Bring your solution into Docusign. Reach over 1.6M customers.

Docusign is now extensible. Overcome challenges with disconnected products and inaccessible data by bringing your solutions into Docusign and publishing to 1.6M customers in the App Center.

Learn more

Top comments (0)

Image of Docusign

🛠️ Bring your solution into Docusign. Reach over 1.6M customers.

Docusign is now extensible. Overcome challenges with disconnected products and inaccessible data by bringing your solutions into Docusign and publishing to 1.6M customers in the App Center.

Learn more