FILES := $(wildcard *.el) PACKAGE_TARGETS := $(addprefix package-,$(FILES)) package: $(PACKAGE_TARGETS) package-oni-conf package-oni-css package-oni-elisp \ package-oni-haml package-oni-html package-oni-nxml package-oni-org \ package-oni-php package-%: % emacs --batch \ --load oni-package.el \ --funcall package-initialize \ --eval '(package-upload-file "$^")' package-oni-conf: emacs --batch \ --load oni-package.el \ --funcall package-initialize \ --eval "(package-upload-file (car (sort (file-expand-wildcards \"oni-conf/dist/*.tar\") #'string>)))" package-oni-css: emacs --batch \ --load oni-package.el \ --funcall package-initialize \ --eval "(package-upload-file (car (sort (file-expand-wildcards \"oni-css/dist/*.tar\") #'string>)))" package-oni-elisp: emacs --batch \ --load oni-package.el \ --funcall package-initialize \ --eval "(package-upload-file (car (sort (file-expand-wildcards \"oni-elisp/dist/*tar\") #'string>)))" package-oni-haml: emacs --batch \ --load oni-package.el \ --funcall package-initialize \ --eval "(package-upload-file (car (sort (file-expand-wildcards \"oni-haml/dist/*.tar\") #'string>)))" package-oni-html: emacs --batch \ --load oni-package.el \ --funcall package-initialize \ --eval "(package-upload-file (car (sort (file-expand-wildcards \"oni-html/dist/*.tar\") #'string>)))" package-oni-nxml: emacs --batch \ --load oni-package.el \ --funcall package-initialize \ --eval "(package-upload-file (car (sort (file-expand-wildcards \"oni-nxml/dist/*.tar\") #'string>)))" package-oni-org: emacs --batch \ --load oni-package.el \ --funcall package-initialize \ --eval "(package-upload-file (car (sort (file-expand-wildcards \"oni-org/dist/*.tar\") #'string>)))" package-oni-php: emacs --batch \ --load oni-package.el \ --funcall package-initialize \ --eval "(package-upload-file (car (sort (file-expand-wildcards \"oni-php/dist/*.tar\") #'string>)))" install-%: emacs --batch \ --load oni-package.el \ --funcall package-initialize \ --eval '(package-refresh-contents)' \ $(foreach DEP,$(DEPS),--eval "(package-install-file \"$(DEP).el\")") \ --eval "(package-install-file \"$*.el\")" install-oni-conf: emacs --batch \ --load oni-package.el \ --funcall package-initialize \ --eval '(package-refresh-contents)' \ $(foreach DEP,$(DEPS),--eval "(package-install-file \"$(DEP).el\")") \ --eval "(package-install-file (car (sort (file-expand-wildcards \"oni-conf/dist/*.tar\") #'string>)))" install-oni-css: emacs --batch \ --load oni-package.el \ --funcall package-initialize \ --eval '(package-refresh-contents)' \ $(foreach DEP,$(DEPS),--eval "(package-install-file \"$(DEP).el\")") \ --eval "(package-install-file (car (sort (file-expand-wildcards \"oni-css/dist/*.tar\") #'string>)))" install-oni-elisp: emacs --batch \ --load oni-package.el \ --funcall package-initialize \ --eval '(package-refresh-contents)' \ $(foreach DEP,$(DEPS),--eval "(package-install-file \"$(DEP).el\")") \ --eval "(package-install-file (car (sort (file-expand-wildcards \"oni-elisp/dist/*.tar\") #'string>)))" install-oni-haml: emacs --batch \ --load oni-package.el \ --fluncall package-initialize \ --eval '(package-refresh-contents)' \ $(foreach DEP,$(DEPS),--eval "(package-install-file \"$(DEP).el\")") \ --eval "(package-install-file (car (sort (file-expand-wildcards \"oni-haml/dist/*.tar\") #'string>)))" install-oni-html: emacs --batch \ --load oni-package.el \ --fluncall package-initialize \ --eval '(package-refresh-contents)' \ $(foreach DEP,$(DEPS),--eval "(package-install-file \"$(DEP).el\")") \ --eval "(package-install-file (car (sort (file-expand-wildcards \"oni-html/dist/*.tar\") #'string>)))" install-oni-nxml: emacs --batch \ --load oni-package.el \ --fluncall package-initialize \ --eval '(package-refresh-contents)' \ $(foreach DEP,$(DEPS),--eval "(package-install-file \"$(DEP).el\")") \ --eval "(package-install-file (car (sort (file-expand-wildcards \"oni-nxml/dist/*.tar\") #'string>)))" install-oni-org: emacs --batch \ --load oni-package.el \ --fluncall package-initialize \ --eval '(package-refresh-contents)' \ $(foreach DEP,$(DEPS),--eval "(package-install-file \"$(DEP).el\")") \ --eval "(package-install-file (car (sort (file-expand-wildcards \"oni-org/dist/*.tar\") #'string>)))" install-oni-php: emacs --batch \ --load oni-package.el \ --fluncall package-initialize \ --eval '(package-refresh-contents)' \ $(foreach DEP,$(DEPS),--eval "(package-install-file \"$(DEP).el\")") \ --eval "(package-install-file (car (sort (file-expand-wildcards \"oni-php/dist/*.tar\") #'string>)))" test-%: install-% emacs --batch \ --load oni-package.el \ --funcall package-initialize \ --load ert \ --load "test/$*-test.el" \ --eval "(setq ert-batch-backtrace-right-margin nil)" \ --funcall ert-run-tests-batch-and-exit test-oni-bookmark: DEPS := oni-data-dir test-oni-conf: DEPS := oni-yasnippet test-oni-css: DEPS := oni-company oni-fci test-oni-php: DEPS := oni-flycheck oni-company oni-fci test-oni-elisp: DEPS := oni-company oni-flycheck oni-paredit oni-fci \ oni-yasnippet clean: rm -fv $(FILES)