Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Somewhat predictably zsh also has a digraphs¹ feature, via the insert-composed-char function². Supported characters can be seen in source³, and beyond that there is the insert-unicode-char² function for when you need it.

I flit between regular compose key input and zsh/vim digraphs in a way that makes no sense to me whatsoever. Compose ^1, AltGr+1 or C-k 1S all kind of feel natural to me, but the advantage of the ZLE method is that you can also use it to preview characters which can be useful if you want to test something out while in another widget or find the hex value to insert using some other tool.

¹ https://datatracker.ietf.org/doc/html/rfc1345#section-2.3

² https://zsh.sourceforge.io/Doc/Release/User-Contributions.ht...

³ https://github.com/zsh-users/zsh/blob/master/Functions/Zle/d...




Consider applying for YC's Fall 2025 batch! Applications are open till Aug 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: