X-Git-Url: https://iankelling.org/git/?p=dot-emacs;a=blobdiff_plain;f=compile-init-dir.el;h=3bdcf4bd46f1a4ca4d0b721ce2df91301ea41f05;hp=2427db7b588f07de0a42292be40dcfd9d86874f6;hb=5e923649cbae5acd7fede8f17e26e1173242a6c6;hpb=3acacbcc3c60e46ba8c81f862b0972d94ff9ef36 diff --git a/compile-init-dir.el b/compile-init-dir.el index 2427db7..3bdcf4b 100644 --- a/compile-init-dir.el +++ b/compile-init-dir.el @@ -13,12 +13,23 @@ ;; You should have received a copy of the GNU General Public License ;; along with this program. If not, see . +;; batch mode doesn't do package-initialize, so we need to call it to +;; setup the load-path for dash + +(setq force (getenv "FORCE_RECOMPILE")) +(package-initialize) (require 'dash) +;; i was using git versions of gnus & bbdb and they +;; needed to run make instead of just byte compile the dir. +;; I'm not anymore, but leaving this in case I do or there +;; are similar packages. (cd "~/.emacs.d/src") (--map (when (and (not (string= it "gnus")) (not (string= it "bbdb")) + (not (string= it ".")) + (not (string= it "..")) (file-directory-p it)) - (byte-recompile-directory (expand-file-name it) 0 t)) + (byte-recompile-directory (expand-file-name it) 0 force)) (directory-files ".")) -(byte-recompile-directory (expand-file-name "~/.emacs.d/elpa") 0 t) -(byte-recompile-file (expand-file-name "~/.emacs.d/my-init.el") t) +(byte-recompile-directory (expand-file-name "~/.emacs.d/elpa") 0 force) +(byte-recompile-file (expand-file-name "~/.emacs.d/my-init.el") force)