I’d like to put my dotConfig files into DropBox, including my .emacs.d folder. I’d like to use these across computers and across OS’s. I’ve split out part of my init.el into per-computer files (whose location is specified with an environment variable) to help its this.

Is there a way to tell straight.el to save the working files somewhere other than ~/.emacs.d/straight?


A cursory look at the sources (I do not have the package installed) suggests that straight-base-dir is the operative variable:

Directory in which the straight/ subdirectory is created. Defaults to `user-emacs-directory'.

So customize it and see if it works.

  • 1
    This worked! I was using an older version so it wasn't present (or, therefore, documented) in the straight.el that I had installed. I switched to the 'develop' branch and it's now working great. Thanks! – MikeTheTall Sep 6 '20 at 3:20
  • 1
    Nice! Frankly, it was an untested guess, so I'm glad it worked. – NickD Sep 6 '20 at 13:09
  • Looks like I spoke a bit too soon. It mostly works but straight.el and org end up in the normal place instead of straight-base-dir. I ended up using a symbolic link to a folder outside of Dropbox and then marking the link as hidden from Db. – MikeTheTall Sep 10 '20 at 14:53
  • That's where all the code should be installed - but you mostly want the data files out of there (unless you are sharing them too of course). I'm not sure what you mean by "org": do you mean things like org.el (the code)? Or do you mean your Org mode files (the data)? If the former, I don't see how it makes a difference. If the latter (and you don't want to share them with other computers), just put them somewhere else and adjust things like org-agenda-files and friends. – NickD Sep 10 '20 at 20:31

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.