Skip to content

Commit 45d08c6

Browse files
committed
Makefile for building ELPA-packages.
Requires `package-build.el' from https://github.com/milkypostman/melpa to be available in your Emacs load-path. Requires [pandoc](http://johnmacfarlane.net/pandoc/) to generate README from README.md. Added dir file for Info documentation.
1 parent bfe90a5 commit 45d08c6

File tree

3 files changed

+61
-0
lines changed

3 files changed

+61
-0
lines changed

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
README
2+
flymake-csslint-*.tar
3+
flymake-csslint-pkg.el
4+
flymake-csslint.info

Makefile

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
.PHONY: all clean install
2+
3+
ARCHIVE_NAME:=flymake-csslint
4+
VERSION:=$(shell emacs --batch --eval "(with-temp-buffer \
5+
(require 'package)\
6+
(insert-file \"$(ARCHIVE_NAME).el\")\
7+
(princ (aref (package-buffer-info) 3)))")
8+
PACKAGE_NAME:=$(ARCHIVE_NAME)-$(VERSION)
9+
10+
all: $(PACKAGE_NAME).tar
11+
12+
$(ARCHIVE_NAME).info: README.md
13+
pandoc -t texinfo $^ | makeinfo -o $@
14+
15+
README: README.md
16+
pandoc --atx-headers -t plain -o $@ $^
17+
18+
# requires package-build.el from https://github.com/milkypostman/melpa
19+
# to be available in your emacs load-path
20+
$(ARCHIVE_NAME)-pkg.el: $(ARCHIVE_NAME).el
21+
emacs --batch --user `whoami` --eval "(progn \
22+
(require 'package-build) \
23+
(pb/write-pkg-file \
24+
\"$(ARCHIVE_NAME)-pkg.el\" \
25+
(with-temp-buffer \
26+
(insert-file \"$(ARCHIVE_NAME).el\") \
27+
(package-buffer-info))))"
28+
29+
# create a tar ball in package.el format for uploading to http://marmalade-repo.org
30+
$(PACKAGE_NAME).tar: README $(ARCHIVE_NAME).el $(ARCHIVE_NAME)-pkg.el $(ARCHIVE_NAME).info dir
31+
tar -c -s "@^@$(PACKAGE_NAME)/@" -f $(PACKAGE_NAME).tar $^
32+
33+
install: $(PACKAGE_NAME).tar
34+
emacs --batch --user `whoami` --eval "(progn \
35+
(package-initialize)\
36+
(package-install-file \"`pwd`/$(PACKAGE_NAME).tar\"))"
37+
38+
clean:
39+
$(RM) $(ARCHIVE_NAME)-*.tar $(ARCHIVE_NAME)-pkg.el README $(ARCHIVE_NAME).info

dir

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
This is the file .../info/dir, which contains the
2+
topmost node of the Info hierarchy, called (dir)Top.
3+
The first time you invoke Info you start off looking at this node.
4+

5+
File: dir, Node: Top This is the top of the INFO tree
6+
7+
This (the Directory node) gives a menu of major topics.
8+
Typing "q" exits, "?" lists all Info commands, "d" returns here,
9+
"h" gives a primer for first-timers,
10+
"mEmacs<Return>" visits the Emacs manual, etc.
11+
12+
In Emacs, you can click mouse button 2 on a menu item or cross reference
13+
to select it.
14+
15+
* Menu:
16+
17+
Programming
18+
* Flymake CSSLinr: (flymake-csslint). Making flymake work with CSSLint.

0 commit comments

Comments
 (0)