Correctly handle installed packages and custom file
This commit is contained in:
parent
0cdab1766c
commit
e56e405cf1
@ -238,8 +238,10 @@ DESIRED-PKGS unless NO-SET-SELECTED is non-nil"
|
||||
(emodule/print-log "*** Delete packages ***")
|
||||
(emodule/delete-pkgs delete-pkgs)))
|
||||
|
||||
;; Update `package-selected-packages'
|
||||
(unless no-set-selected
|
||||
(customize-save-variable 'package-selected-packages desired-pkgs)))
|
||||
(setq package-selected-packages desired-pkgs)
|
||||
(customize-save-variable 'package-selected-packages package-selected-packages)))
|
||||
|
||||
;;; Init functions:
|
||||
|
||||
|
12
init.el
12
init.el
@ -89,6 +89,12 @@
|
||||
|
||||
(setq-default custom-file (emacs-dir "custom.el"))
|
||||
|
||||
;; -----------------------------------------------------------------------------------------------
|
||||
;; Load any custom variables straight away to make sure all custom values carry over.
|
||||
;; -----------------------------------------------------------------------------------------------
|
||||
|
||||
(load custom-file 'noerror)
|
||||
|
||||
|
||||
;; ******************************************************************************************** ;;
|
||||
;; ;;
|
||||
@ -133,12 +139,6 @@
|
||||
;; ;;
|
||||
;; ******************************************************************************************** ;;
|
||||
|
||||
;; -----------------------------------------------------------------------------------------------
|
||||
;; Load any custom variables.
|
||||
;; -----------------------------------------------------------------------------------------------
|
||||
|
||||
(load custom-file 'noerror)
|
||||
|
||||
) ;; Reset garbage collection settings.
|
||||
|
||||
(provide 'init)
|
||||
|
Reference in New Issue
Block a user