This repository has been archived by the owner on Jun 19, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
44 lines (36 loc) · 1.61 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
REPO ?= github.com/kubenav/bind
VERSION ?= $(shell git describe --tags)
.PHONY: bindings-android bindings-ios dependencies release-major release-minor release-patch test
bindings-android:
GO111MODULE=off gomobile bind -o request.aar -target=android ${REPO}/request
tar -zcvf request.aar-${VERSION}-android.tar.gz request.aar
bindings-ios:
GO111MODULE=off gomobile bind -o Request.framework -target=ios ${REPO}/request
tar -zcvf Request.framework-${VERSION}-ios.tar.gz Request.framework
dependencies:
GO111MODULE=off go get -u golang.org/x/mobile/cmd/gomobile
GO111MODULE=off go get -u github.com/aws/aws-sdk-go/...
GO111MODULE=off go get -u github.com/Azure/azure-sdk-for-go/services/containerservice/mgmt/2020-01-01/containerservice
GO111MODULE=off go get -u github.com/coreos/go-oidc
GO111MODULE=off go get -u golang.org/x/oauth2
GO111MODULE=off go get -u gopkg.in/yaml.v2
release-major:
$(eval MAJORVERSION=$(shell git describe --tags --abbrev=0 | sed s/v// | awk -F. '{print $$1+1".0.0"}'))
git checkout master
git pull
git tag -a $(MAJORVERSION) -m 'Release $(MAJORVERSION)'
git push origin --tags
release-minor:
$(eval MINORVERSION=$(shell git describe --tags --abbrev=0 | sed s/v// | awk -F. '{print $$1"."$$2+1".0"}'))
git checkout master
git pull
git tag -a $(MINORVERSION) -m 'Release $(MINORVERSION)'
git push origin --tags
release-patch:
$(eval PATCHVERSION=$(shell git describe --tags --abbrev=0 | sed s/v// | awk -F. '{print $$1"."$$2"."$$3+1}'))
git checkout master
git pull
git tag -a $(PATCHVERSION) -m 'Release $(PATCHVERSION)'
git push origin --tags
test:
GO111MODULE=off go test -v ./...