-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
77 lines (55 loc) · 1.44 KB
/
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
.PHONY: types hdmi-switch-remote-darwin-amd64
.SUFFIXES:
GULP = $(shell npm bin)/gulp
NAME = hdmi-switch-remote
build: $(NAME)
all: node_modules bower_components public/hello.js public/index.html public/vendor.js public/hello.css public/angular-material.min.css public/font-awesome.min.css public/fonts
go get -d -v ./...
go get -v github.com/GeertJohan/go.rice/rice
run\:dev: $(NAME)-bare all
./$(NAME)-bare
$(NAME)-bare: $(shell find . -name "*.go") all
rm -rf public.rice-box.go
go build -o $(NAME)-bare
$(NAME): all
rm -rf $(NAME)
rm -rf public.rice-box.go
go build -o $(NAME)
rice append --exec $(NAME)
node_modules:
npm -q update
bower_components:
bower -q update
public/hello.js: app/hello.ls
$(GULP)
public/index.html: app/index.jade
$(GULP)
public/vendor.js: bower.json
$(GULP)
public/hello.css: app/hello.styl
$(GULP)
public/angular-material.min.css:
$(GULP)
public/font-awesome.min.css:
$(GULP)
public/fonts:
$(GULP)
types:
java -jar bower_components/closure-compiler/compiler.jar \
--warning_level=VERBOSE \
--externs support/externs/angular-1.2.js \
--externs support/externs/externs.js \
--angular_pass \
tmp/hello.js
public.rice-box.go: all
rice embed-go
hello_embedded: public.rice-box.go
go build
setup:
# For rice
sudo apt-get install zip
npm install -q -g bower gulp
$(NAME)-darwin-amd64: all
rm -rf $(NAME)-darwin-amd64
rice embed-go
GOOS=darwin GOARCH=amd64 go build -o $(NAME)-darwin-amd64