Elisp/Emacs Examples

Caio Rordrigues has an excellent resource for beginning/intermediate Elisp programmers that also lists some of the common Emacs customizations that many Emacs users end up making. For example, it tells you how to turn off requiring a “yes” or “no” response to certain prompts and enabling a simple ‘y’ or ‘n’ instead.

The real meat, though, is the list of Elisp examples. You can think of it as an Elisp cookbook. It covers things like filtering lists, reading or writing from/to strings, splitting strings, mapping, structures, the loop macro, working with buffers and files, and a host of other useful examples. It’s fun just to read through it and when you do, you’re likely to learn a few things you didn’t know.

This is a really useful resource, especially for learning Elisp idioms and what sort of functions are available. As I’ve written before, the basics of Lisp programming are easy; it’s learning the library that’s hard. That’s especially true of Elisp, which has many specialized functions for editing text. Sometimes you know what you want to do but it’s not clear what terms you should search for to tell you how to implement it. Rordrigues’ examples covers most types of actions and will at least get you to the right set of functions. Even new Emacs users will find the section on customizations helpful.

This entry was posted in General and tagged , . Bookmark the permalink.