I want to eval my ~/.emacs.d/init.el file periodically from CLI (cron) since it generates other files that I use in my projects according to some extra data.

Something like "emacs -q -eval-file ~/.emacs.d/init.el", or something like this.

How can I do it ?


1 Answer 1


Emacs has an --eval option that you can use, details are here. But if you do this a lot, you may not want to start the entire emacs all the time. Instead, you can run the emacs-server and then simply use the much more light-weight emacsclient; see here.

You must log in to answer this question.