]> git.wh0rd.org - chrome-ext/waterfall-buildbot-clicker.git/blob - Makefile
initial code
[chrome-ext/waterfall-buildbot-clicker.git] / Makefile
1 # http://www.html5rocks.com/en/tutorials/developertools/sourcemaps/
2 CLOSURE = closure-compiler --language_in ECMASCRIPT5 --js $1 --create_source_map $1.map --source_map_format=V3 --js_output_file $1.min
3 YUICOMPRESSOR = yuicompressor
4 HTMLMINIFIER = html-minifier \
5 --collapse-whitespace \
6 --remove-attribute-quotes \
7 --remove-redundant-attributes \
8 --remove-empty-attributes \
9 --remove-comments
10
11 all:
12
13 min: css-min html-min js-min
14
15 %.js.min: %.js
16 $(call CLOSURE,$<)
17
18 JS_FILES = $(shell grep '[.]js$$' manifest.files)
19 js-min: $(JS_FILES:=.min)
20
21 %.css.min: %.css
22 $(YUICOMPRESSOR) $< > $@
23
24 CSS_FILES = $(shell grep '[.]css$$' manifest.files)
25 css-min: $(CSS_FILES:=.min)
26
27 %.html.min: %.html
28 $(HTMLMINIFIER) $< > $@
29
30 HTML_FILES = $(shell grep '[.]html$$' manifest.files)
31 html-min: $(HTML_FILES:=.min)
32
33 check: html-min css-min js-min
34
35 dist:
36 ./makedist.sh
37
38 .PHONY: all clean check css-min dist html-min js-min