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

Paredit made a massive difference when I was writing Lisp. It does take some getting used to, but pretty sure it was a net positive after a week of use.

I actually started enabling it when writing other languages (Python/C++) to see if it could do its magic there.



You probably know that, but there is smartparens mode which does similar magic to non-lisp languages: https://github.com/Fuco1/smartparens


In recent years, I have been spoiled by doom-emacs (and previously spacemacs). They have made everything work out of the box for me to such an extent that I mostly don't know what's active--I've just learned the right leader combination to get what I need done.

It turns out I've been using smartparens without realizing--just opened a file and checked the active modes to find out.

The keys I've learned are (using evil):

- [Visual mode] S -> surround by a pair

- [Visual mode] d <char> -> delete pair of <char>

- [Visual mode] c <c1> <c2> -> replace pair of <c1> with pair of <c2>

Those along with C-M-k to kill a sexp and % to go to the other end of a pair have been all I need for my work (the vast majority C/C++ and Python).

One thing I keep putting off is figuring out a way to jump to the opening/closing quotes. For those I still have to go medieval if there's any nesting.


I did not know that!




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: