Remove doom-elpa-dir variable

And just use package-user-dir. No need for two variable when one will
do.
This commit is contained in:
Henrik Lissner 2019-09-24 20:49:24 -04:00
parent 22e3dfa677
commit 45240699e0
No known key found for this signature in database
GPG key ID: 5F6C0EA160557395
4 changed files with 5 additions and 9 deletions

View file

@ -359,7 +359,7 @@ This should be run whenever your `doom!' block or update your packages."
(print-group!
(if (and (not force-p)
(file-exists-p doom-package-autoload-file)
(not (file-newer-than-file-p doom-elpa-dir doom-package-autoload-file))
(not (file-newer-than-file-p package-user-dir doom-package-autoload-file))
(not (cl-loop for dir in (straight--directory-files (straight--build-dir))
if (cl-find-if
(lambda (dir)

View file

@ -439,7 +439,7 @@ a list of packages that will be updated."
(package-initialize))
(let ((packages (cl-loop for (package desc) in package-alist
for dir = (package-desc-dir desc)
if (file-in-directory-p dir doom-elpa-dir)
if (file-in-directory-p dir package-user-dir)
collect (cons package dir))))
(if (not package-alist)
(progn (print! (info "No ELPA packages to purge"))

View file

@ -74,8 +74,8 @@ missing) and shouldn't be deleted.")
;; shouldn't be using it, but it may be convenient for quick package testing.
(setq package--init-file-ensured t
package-enable-at-startup nil
package-user-dir doom-elpa-dir
package-gnupghome-dir (expand-file-name "gpg" doom-elpa-dir)
package-user-dir (concat doom-local-dir "elpa/")
package-gnupghome-dir (expand-file-name "gpg" package-user-dir)
;; I omit Marmalade because its packages are manually submitted rather
;; than pulled, so packages are often out of date with upstream.
package-archives

View file

@ -61,9 +61,6 @@ dependencies or long-term shared data. Must end with a slash.")
Use this for files that change often, like cache files. Must end with a slash.")
(defvar doom-elpa-dir (concat doom-local-dir "elpa/")
"Where package.el plugins (and their caches) are stored. Must end with a slash.")
(defvar doom-docs-dir (concat doom-emacs-dir "docs/")
"Where Doom's documentation files are stored. Must end with a slash.")
@ -517,8 +514,7 @@ to least)."
;; Create all our core directories to quell file errors
(dolist (dir (list doom-local-dir
doom-etc-dir
doom-cache-dir
doom-elpa-dir))
doom-cache-dir))
(unless (file-directory-p dir)
(make-directory dir 'parents)))