Andrey Listopadov

Tags / emacs-lisp

There was a weird thought going over and over in my head, regarding my Emacs configuration, and it extends to the other projects I do both at home and at work. You see, my configuration is riddled with custom code, and up until recently I had mixed feelings about that.
In the previous post on the subject I’ve described how one can create a custom compilation mode for any language. In the Dynamically extracting filenames from compiler output section I’m talking about various issues with how Clojure reports problem locations. The main problem is when the problem is inside of a dependency, and be it your own library, or a third-party one it’s equally tedious to go and look into it because the dependency usually is a jar file somewhere in the ~/.
Recently, I decided to try the now inbuilt LSP client called Eglot. I’ve been using the lsp-mode package for some years and while I don’t have any problems with it, I decided to try the in-house solution. Though, I already tried Eglot in the past, and it didn’t work for me, due to some complications with the language I’ve tried to use it with.
Recently I read a post by @nikitonsky about writing a custom REPL for Clojure and Sublime Text. What got my attention was a way of implementing a protocol over a plain Clojure REPL. In the post, Nikita describes a way to “upgrade” the connection by sending code that basically implements a new REPL to the main REPL process.
TIL that Emacs Lisp has had generators since 2016, and generators are a cool feature in any language in my opinion! In short, Emacs has the generator.el package as it’s part since version 25.1. The generators are implemented via transforming code and act like iterators, even most of the functions are called iter-something.
I’ve published two new packages for Emacs: - region-bindings.el and common-lisp-modes.el. Both are quite small and were a part of my configuration for a long time, but after small refactoring of my init.el I’ve decided to extract them. The first one, region-bindings is a from-scratch re-implementation of region-bindings-mode.
Another post in the not-so-series about Emacs configuration. Today I will describe my configuration for managing the compilation-error-regexp-alist variable in a way that is meaningful for the current project I’m working on. Some time ago I faced a problem that the compilation-error-regexp-alist variable contains far too many entries for different languages by default.
In Emacs version 28 Emacs developers introduced so-called read symbol shorthands. If you’re interested in the rationale, feel free to search the Emacs developer mailing list for the discussion. However, it does seem that not everyone likes the idea of shorthands as a substitution for namespaces (or packages, if you’re coming from Common Lisp).
Or “when you don’t have topics to write about, write about how you do your writing”. Ahem. I like my blog workflow, it makes me want to return to writing more often, and because of this, I capture way more thoughts than I would usually do if I didn’t have a blog.
I use Emacs mainly for programming, but I also write a lot of non-code in it, either for this blog, documentation for my projects, or just when I take notes. And I do it with a git-friendly style of formatting with a single sentence per line.
Newer Page 1 of 2 Older