Skip to content

Commit e59a2fb

Browse files
committed
make target to package for distribution via ELPA
This address the request posed in issue 61. eschulte#61
1 parent 5e3e39b commit e59a2fb

File tree

2 files changed

+24
-0
lines changed

2 files changed

+24
-0
lines changed

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,3 +51,7 @@ secret.org
5151
.emacs.desktop*
5252
.*~
5353
agent/*
54+
55+
## package directory
56+
literate-emacs-starter-kit-*/
57+
literate-emacs-starter-kit-*.tar

Makefile

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,5 +29,25 @@ doc/index.html:
2929
cp doc/starter-kit.html doc/index.html
3030
echo "Documentation published to doc/"
3131

32+
# Packaging
33+
NAME=literate-emacs-starter-kit
34+
VERSION=1.0.0
35+
DOC=A literate version of the Emacs Starter Kit.
36+
REQ=(emacs "24.3")
37+
DEFPKG=(define-package "$(NAME)" "$(VERSION)"\n "$(DOC)"\n (quote $(REQ)))
38+
PACKAGE=$(NAME)-$(VERSION)
39+
40+
$(PACKAGE): $(wildcard *.org) init.el Makefile
41+
mkdir -p $(PACKAGE)
42+
cp $^ $(PACKAGE)
43+
$(BATCH) starter-kit.org --eval "(org-export-to-file 'ascii \"$(PACKAGE)/README\")"
44+
echo -e '$(DEFPKG)' > $(PACKAGE)/$(NAME)-pkg.el
45+
46+
$(PACKAGE).tar: $(PACKAGE)
47+
tar cf $@ $<
48+
49+
package: $(PACKAGE).tar
50+
3251
clean:
3352
rm -f *.elc *.aux *.tex *.pdf starter-kit*.el starter-kit*.html doc/*html *~ .starter-kit*.part.org
53+
rm -rf $(PACKAGE).tar $(PACKAGE)

0 commit comments

Comments
 (0)