1

Basically, I share a single .emacs.d across several machines and have one package that I only want on my home machine (org-journal). I like using the package manager to keep this up to date, but it loads the package on every machine which causes some interference to a normal work flow.

Is there a way to get the package manager to skip loading this one package but load all others?

ETA: I tried only loading it on my desktop via

(when (string-equal (system-name) "will-desktop") 
     (require 'org-journal))

but that didn't work because using (package-initialize) early on in my init.el automatically loads it.

William Everett
  • 751
  • 1
  • 8
  • 18

1 Answers1

2

See the package-load-list variable.

The default value is (all), and the docstring says that all affects only packages not specified by other elements, so by my reading, you could simply add the following to inhibit org-journal:

(setq package-load-list '((org-journal nil) all))

If you're forcibly initialising the package manager in your init file, make sure you make this change beforehand.

Edit: Tested and updated/fixed. add-to-list was wrong, as the variable isn't already defined at that point.

phils
  • 71,335
  • 11
  • 153
  • 198
  • Brilliant. I saw that variable, but didn't know there was a way to exclude one entry like that. I like that I learned something new about emacs lisp today. – William Everett Jul 05 '14 at 00:23