doomemacs/Makefile

40 lines
961 B
Makefile
Raw Normal View History

# Ensure emacs always runs from this makefile's PWD
EMACS=emacs --batch --eval "(setq user-emacs-directory default-directory)"
2016-03-26 01:37:48 +08:00
# Tasks
2017-02-03 10:56:52 +08:00
all: install update autoloads
2016-05-29 12:40:13 +08:00
2017-02-03 10:56:52 +08:00
install: init.el
@$(EMACS) -l core/core.el -f 'doom/packages-install'
2017-02-03 10:56:52 +08:00
update: init.el
@$(EMACS) -l core/core.el -f 'doom/packages-update'
2016-03-26 01:37:48 +08:00
autoremove: init.el
@$(EMACS) -l core/core.el -f 'doom/packages-autoremove'
autoloads: init.el
@$(EMACS) -l init.el -f 'doom/refresh-autoloads'
2016-03-26 01:37:48 +08:00
compile: init.el clean-elc
@$(EMACS) -l init.el -f 'doom/byte-compile'
2017-02-03 10:56:52 +08:00
2017-02-06 14:24:37 +08:00
compile-lite: init.el clean-elc
@$(EMACS) -l core/core.el --eval '(doom/byte-compile t)'
2016-03-26 01:37:48 +08:00
clean:
2017-01-17 12:30:37 +08:00
@rm -fv init.elc
@find {core,modules} -type f -iname '*.elc' -exec rm \-fv {} \;
2016-04-08 13:44:10 +08:00
clean-cache:
@$(EMACS) -l core/core.el --eval '(delete-directory doom-cache-dir t)'
2017-02-04 08:17:09 +08:00
test:
@$(EMACS) -l test/init.el -f 'doom-run-tests'
2017-02-04 08:17:09 +08:00
2017-01-31 17:31:14 +08:00
init.el:
2017-02-08 15:02:51 +08:00
@[ -f init.el ] || $(error No init.el file; create one or copy init.example.el)
2017-01-31 17:31:14 +08:00
2017-02-04 08:17:09 +08:00
.PHONY: all test