forked from YahooArchive/boomerang
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
32 lines (26 loc) · 853 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
PLUGINS :=
VERSION := $(shell sed -ne '/^BOOMR\.version/{s/^.*"\([^"]*\)".*/\1/;p;q;}' boomerang.js)
DATE := $(shell date +%s)
MINIFIER := cat
all: boomerang-$(VERSION).$(DATE).js
usage:
echo "Create a release version of boomerang:"
echo " make"
echo ""
echo "Create a release version of boomerang with the dns plugin:"
echo " make PLUGINS=dns.js"
echo ""
echo "Create a yuicompressor minified release version of boomerang:"
echo " make MINIFIER=\"java -jar /path/to/yuicompressor-2.4.2.jar --type js\""
echo ""
echo "Create a jsmin minified release version of boomerang:"
echo " make MINIFIER=\"/path/to/jsmin\""
echo ""
boomerang-$(VERSION).$(DATE).js: boomerang.js $(PLUGINS)
echo
echo "Making $@ ..."
echo "using plugins: $(PLUGINS)..."
cat boomerang.js $(PLUGINS) | $(MINIFIER) > $@ && echo "done"
echo
.PHONY: all
.SILENT: