-
Notifications
You must be signed in to change notification settings - Fork 18
/
Copy pathMakefile
42 lines (29 loc) · 810 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
33
34
35
36
37
38
39
40
41
42
PAGES = $(patsubst %.jsx, %.js, $(wildcard lib/pages/*.jsx))
COMPONENTS = $(patsubst %.jsx, %.js, $(wildcard lib/components/*.jsx))
COMPILED = $(PAGES) $(COMPONENTS)
build: components index.js twitter-audition.css lib $(COMPILED)
@component build --dev -s twitterAudition -o web -n build
twitter-audition.css: index.less less
@lessc index.less > $@
lib/pages/%.js: lib/pages/%.jsx
@jsx $< > $@
lib/components/%.js: lib/components/%.jsx
@jsx $< > $@
components: component.json
@component install --dev
clean:
rm -fr build components template.js
view:
@xdg-open web/index.html
test: lint test-only
lint:
jshint *.js lib test
test-only:
mocha -R spec
gh-pages: build
cp -r web w
git co gh-pages
rm -rf bootstrap font-awesome
mv w/* ./
rmdir w
.PHONY: clean test test-only lint gh-pages