emacs-literal-config icon indicating copy to clipboard operation
emacs-literal-config copied to clipboard

emacs need custom.el file to start cleanly

Open heikkil opened this issue 11 years ago • 2 comments

By deleting our custom.el file you cause emacs not to start cleanly. One line instruction have been added to emacs.org so that other users who fork this repo are not affected. Note: The empty custom.el is included in the commit that will overwrite any custom.el you might happen to have.

heikkil avatar Oct 31 '13 07:10 heikkil

I've come up with a better way to solve this: let lisp do the work of testing for the file existence and creating it if needed:

#+name: customize-config #+BEGIN_SRC emacs-lisp (setq custom-file (expand-file-name "custom.el" user-emacs-directory)) (unless (file-exists-p custom-file) (write-region "" nil custom-file)) (load custom-file) #+END_SRC

heikkil avatar Nov 03 '13 07:11 heikkil

👍 it is enough to add an empty custom.el, but emacs will complain if you follow the instruction as-is @joodie :)

Heliosmaster avatar Apr 27 '16 06:04 Heliosmaster