Sort & optimize package list on 'doom purge'
This commit is contained in:
parent
58fb9faf3a
commit
b854a089eb
1 changed files with 8 additions and 6 deletions
|
@ -446,12 +446,14 @@ Unless AUTO-ACCEPT-P is non-nil, this function will prompt for confirmation with
|
||||||
a list of packages that will be removed."
|
a list of packages that will be removed."
|
||||||
(print! (start "Searching for orphaned packages to purge (for the emperor)..."))
|
(print! (start "Searching for orphaned packages to purge (for the emperor)..."))
|
||||||
(cl-destructuring-bind (&optional builds-to-purge repos-to-purge repos-to-regraft)
|
(cl-destructuring-bind (&optional builds-to-purge repos-to-purge repos-to-regraft)
|
||||||
(list (cl-remove-if (doom-rpartial #'gethash straight--profile-cache)
|
(let ((rdirs (straight--directory-files (straight--repos-dir) nil nil 'sort))
|
||||||
(straight--directory-files (straight--build-dir)))
|
(bdirs (straight--directory-files (straight--build-dir) nil nil 'sort)))
|
||||||
(cl-remove-if (doom-rpartial #'straight--checkhash straight--repo-cache)
|
(list (cl-delete-if (doom-rpartial #'gethash straight--profile-cache)
|
||||||
(straight--directory-files (straight--repos-dir)))
|
bdirs)
|
||||||
(cl-remove-if-not (doom-rpartial #'straight--checkhash straight--repo-cache)
|
(cl-delete-if (doom-rpartial #'straight--checkhash straight--repo-cache)
|
||||||
(straight--directory-files (straight--repos-dir))))
|
rdirs)
|
||||||
|
(cl-delete-if-not (doom-rpartial #'straight--checkhash straight--repo-cache)
|
||||||
|
rdirs)))
|
||||||
(let (success)
|
(let (success)
|
||||||
(print-group!
|
(print-group!
|
||||||
(if (not builds-p)
|
(if (not builds-p)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue