     "Startup Time: %.2f seconds"
     (float-time (time-subtract after-init-time before-init-time)))))
 
-;; load early config
+;; Do the init dance
 (load ng/early-init-file)
-
-;; Check if we have an up-to-date lock file and load it
-;; if so. If not, boot using package.el.
-(if (and (file-exists-p ng/package-lock-file)
-         (file-newer-than-file-p ng/package-lock-file ng/early-init-file)
-	 (file-newer-than-file-p ng/package-lock-file ng/init-file))
-    (load ng/package-lock-file)
-  (progn
-    (require 'package)
-    (package-initialize)
-    (unless (package-installed-p 'use-package)
-      (package-refresh-contents)
-      (package-install 'use-package))
-    (setq use-package-always-ensure t)
-    (delete-file ng/package-lock-file)))  
-
-;; load main config
+(ng/package-initialize) 
 (load ng/init-file)
-
-;; save lock file to speed up future inits
-(when use-package-always-ensure
-  (let ((package-dir (file-truename package-user-dir)))
-    (with-temp-file ng/package-lock-file
-      (insert ";; This file is automatically generated to speed up package loading when the configuration hasn't changed.\n")
-      (dolist (path load-path)
-	(when (string-prefix-p package-dir path)
-	  (insert (format "(add-to-list 'load-path \"%s\")\n" path)))))))
-
-;; load generated config
+(ng/package-save)
 (load custom-file)

(defvar ng/package-lock-file "~/.emacs.d/.ng-package-lock.el"
  "The generated file where package load-paths are cached to be
reused when the config files have not changed.")

;; Set up load path for personal *.el files
(add-to-list 'load-path "~/.emacs.d/lisp")

;;   plain text lock file to remember the load path from a prior
;;   initialization.
;;
;; *  https://blog.d46.us/advanced-emacs-startup
;;
;;   Startup time logging lifted from there. I played with GC settings
;;   and they weren't material so I left it alone. I also removed the
