this post was submitted on 01 Dec 2023
1 points (100.0% liked)

Emacs

297 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

  1. Posts should be emacs related
  2. Be kind please
  3. Yes, we already know: Google results for "emacs" and "vi" link to each other. We good.

Emacs Resources

Emacs Tutorials

Useful Emacs configuration files and distributions

Quick pain-saver tip

founded 1 year ago
MODERATORS
 

Hi there, I'm trying to brush off my emacs and Orgmode since it's been years. I'm hitting a few snags and am also wondering about current standards since there has been many updates.

My goal:

Use Orgmode to customise my emacs and init files while using the Dropbox directory. I would also like to use a custom named init file so it's like eckoinit.el instead of init.el (For easier recognition and modification).

Overall, I'd like to sync and use emacs from different computers using the same configs.

I know one of my current snags is I can't remember how to tell emacs from Orgmode to use a differently named init file. I feel like this should be an obvious answer that I should have found by now and I feel silly.

Thanks for your time!

top 1 comments
sorted by: hot top controversial new old
[–] [email protected] 1 points 8 months ago

Okay, I can't help with the custom init.el name, but "Can't remember how to tell emacs from Orgmode to use a differently named init file." suggests you're trying to use the org document itself as your init.el?

If thats the case, look into org-babel tangle and the auto-tangle package. You can keep the org file in Dropbox, which serves to organize elisp source code blocks that contain your configuration. With this approach, you can segment your init.el with org-mode, and add comments, links, unused older configuration, or any other info into the org document itself. When org-babel-tangle is called, the elisp source code blocks will be placed in the specified location file (look at docs for tangle on how to specify) (~/.bashrc for instance) in the order they appear in the org file.

This literate approach is AWESOME and I suggest anyone who uses org mode does it.