If you ensure that everything that you want to be compiled is currently compiled, you can let https://github.com/emacscollective/auto-compile manage it from there.
this post was submitted on 04 Dec 2023
2 points (100.0% liked)
Emacs
7 readers
1 users here now
A community for the timeless and infinitely powerful editor. Want to see what Emacs is capable of?!
Get Emacs
Rules
- Posts should be emacs related
- Be kind please
- Yes, we already know: Google results for "emacs" and "vi" link to each other. We good.
Emacs Resources
Emacs Tutorials
- Beginner’s Guide to Emacs
- Absolute Beginner's Guide to Emacs
- How to Learn Emacs: A Hand-drawn One-pager for Beginners
Useful Emacs configuration files and distributions
Quick pain-saver tip
founded 1 year ago
MODERATORS
Properly package that code (sounds like you're most of the way there) and let your package manager handle it.
I simply use:
(defun my-recompile-init-eln ()
(interactive)
(byte-compile-file "~/.emacs.d/early-init.el")
(native-compile "~/.emacs.d/early-init.el")
(byte-compile-file "~/.emacs.d/init.el")
(native-compile "~/.emacs.d/init.el"))
I use it manually, but I don't care too much because I don't edit my init files too often anymore. But it shouldn't be too hard to run this function automatically at boot if the .elc
is outdated compared to the .el
.