-
Notifications
You must be signed in to change notification settings - Fork 3
/
Makefile
34 lines (25 loc) · 870 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
VERSION = 0.3
GO_FMT = gofmt -s -w -l .
GO_XC = goxc -os="linux darwin windows" -tasks-="rmbin"
GOXC_FILE = .goxc.local.json
all: deps compile
compile: goxc
goxc:
$(shell echo '{\n "ConfigVersion": "0.9",\n "PackageVersion": "$(VERSION)",' > $(GOXC_FILE))
$(shell echo ' "TaskSettings": {' >> $(GOXC_FILE))
$(shell echo ' "bintray": {\n "apikey": "$(BINTRAY_APIKEY)"' >> $(GOXC_FILE))
$(shell echo ' },' >> $(GOXC_FILE))
$(shell echo ' "publish-github": {' >> $(GOXC_FILE))
$(shell echo ' "apikey": "$(GITHUB_APIKEY)",' >> $(GOXC_FILE))
$(shell echo ' "body": "",' >> $(GOXC_FILE))
$(shell echo ' "include": "*.zip,*.tar.gz,*.deb,go-mesoslog_$(VERSION)_linux_amd64-bin"' >> $(GOXC_FILE))
$(shell echo ' }\n } \n}' >> $(GOXC_FILE))
$(GO_XC)
deps:
go get
format:
$(GO_FMT)
bintray:
$(GO_XC) bintray
github:
$(GO_XC) publish-github