Variable: user-lisp-directory

user-lisp-directory is a customizable variable defined in startup.el.gz.

Value

"~/.emacs.d/user-lisp/"

Documentation

Activate all Lisp files in this directory, if it exists.

All regular files below directories are byte-compiled, scraped for autoload cookies and ensured to be in load-path at startup. To restrict what subdirectories to process, see user-lisp-ignored-directories. Note that byte-compilation and autoload scraping is lazy, occurring only if the file timestamps indicate that it is necessary. For details on how to override this behavior, consult prepare-user-lisp.

If you need Emacs to pick up on updates to this directory that occur after startup, you can also invoke the prepare-user-lisp manually. To disable auto-scraping, see user-lisp-auto-scrape.

Note that this variable must be set in your early-init file, as the variable's value is used before loading the regular init file. Therefore, if you customize it via Customize, you should save your customized setting into your early-init-file.

This variable was added, or its default value changed, in Emacs 31.1.

View in manual

Probably introduced at or before Emacs version 31.1.

Source Code

;; Defined in /usr/src/emacs/lisp/startup.el.gz
(defcustom user-lisp-directory
  (locate-user-emacs-file "user-lisp/")
  "Activate all Lisp files in this directory, if it exists.
All regular files below directories are byte-compiled, scraped for
autoload cookies and ensured to be in `load-path' at startup.  To
restrict what subdirectories to process, see
`user-lisp-ignored-directories'.  Note that byte-compilation and
autoload scraping is lazy, occurring only if the file timestamps
indicate that it is necessary.  For details on how to override this
behavior, consult `prepare-user-lisp'.

If you need Emacs to pick up on updates to this directory that occur
after startup, you can also invoke the `prepare-user-lisp' manually.  To
disable auto-scraping, see `user-lisp-auto-scrape'.

Note that this variable must be set in your early-init file, as the
variable's value is used before loading the regular init file.
Therefore, if you customize it via Customize, you should save your
customized setting into your `early-init-file'."
  :initialize #'custom-initialize-delay
  :type 'directory
  :version "31.1")