forked from Bit-Nation/panthalassa
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
39 lines (38 loc) · 1.1 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
.PHONY: cli build test
list:
@$(MAKE) -pRrq -f $(lastword $(MAKEFILE_LIST)) : 2>/dev/null | awk -v RS= -F: '/^# File/,/^# Finished Make data base/ {if ($$1 !~ "^[#.]") {print $$1}}' | sort | egrep -v -e '^[^[:alnum:]]' -e '^$@$$' | xargs
proto:
protoc --go_out=. api/pb/*.proto
deps:
go get github.com/whyrusleeping/gx
go get github.com/whyrusleeping/gx-go
go get github.com/mattn/goveralls
go get -u github.com/kardianos/govendor
go get github.com/stretchr/testify
install:
gx install
go get ./...
deps_mobile:
go get golang.org/x/mobile/cmd/gomobile
gomobile clean
gomobile init
deps_hack:
gx-go rw
deps_hack_revert:
gx-go uw
ios:
gomobile bind -target ios -o build/panthalassa.framework -v github.com/Bit-Nation/panthalassa
android:
gomobile bind -target android -o build/panthalassa.aar -v github.com/Bit-Nation/panthalassa
build:
go build -o build/panthalassa
test:
go fmt ./...
go test ./...
test_coverage:
go fmt ./...
go test ./... -coverprofile=c.out && go tool cover -html=c.out
coveralls:
goveralls -repotoken ${COVERALS_TOKEN}
cli:
go build -o panthalassa github.com/Bit-Nation/panthalassa/cli