news.ycombinator.com• Aug 18, 2026• 1 min read
Ask HN: How to tune Emacs config for portability: Linux, macOS and Windows?I've been a GNU/Linux-only Emacs user for years, and most of my configuration has naturally evolved around that environment.Now I may need to start using macOS and Windows as well, and I'm realizing that "Emacs is cross-platform" and "my Emacs configuration is cross-platform" are two rather different things.I'm curious how people who maintain a substantial Emacs configuration approach this.My config is fairly modular and tries to stay close to vanilla Emacs where possible, using things like Elpaca, Corfu, Vertico, Eglot, etc. The Linux setup is fast and works exactly the way I want, but I don't want to end up with a giant collection of OS-specific conditionals every time I move between machines.This is my config by the way: https://codeberg.org/jjba23/heks-emacsSome things I'm particularly wondering about:- How do you handle filesystem paths and environment variables cleanly?- Do you abstract OS-specific functionality, or simply use `system-type` / `executable-find` where necessary?- H