Using an org file as (personal) init file

25 views
Skip to first unread message

Konstantinos Vasilakos

unread,
Oct 29, 2016, 6:05:31 PM10/29/16
to Emacs Prelude
Hello, is it possible to use a personal init file in org mode format e.g. ~/.emacs.d/personal/init.org This is ignored right now by the primary init file, and I couldn't find a legit way to achieve this.


Best,
K

Tom Roche

unread,
Oct 29, 2016, 7:46:58 PM10/29/16
to Emacs Prelude
Konstantinos Vasilakos

> is it possible to use a personal init file in org mode format e.g. ~/.emacs.d/personal/init.org

I don't do this, but have seen this done (and if I remember how I'll post a link). That being said, hardcore org-mode'rs seem more often to use a stub init.el which then calls multiple *.org subfiles. (This is like the common .emacs.d pattern where one breaks out functionality to multiple *.el files rather than having one long init.el.) For a popular example, see Eric Schulte's Emacs Starter Kit

https://eschulte.github.io/emacs24-starter-kit/

Konstantinos Vasilakos

unread,
Oct 30, 2016, 5:37:15 AM10/30/16
to Emacs Prelude
Hi again, I managed to do it by putting this in my custom.el file.

(require 'org)
(org-babel-load-file
 (expand-file-name "init.org"
                   "~/.emacs.d/personal/"))

This seems to do the trick, however, it seems that it creates an init.el file tangled from the .org one; I guess this is expected though.

Thanks

best,
K.

Reply all
Reply to author
Forward
0 new messages