-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmakefile
47 lines (35 loc) · 1.18 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
PERCENT := %
DEL := /
BR != shell git branch | grep \* | cut -d ' ' -f2-
bump-patch:
bumpversion patch
bump-minor:
bumpversion minor
up_master:
@echo "on branch $(BR)"
@[ "$(BR)" == "dev" ] && true || (echo "only dev can be used. you on $(BR)" && exit 1)
@[ -z "$(git status --porcelain)" ] && true || (echo "directory not clean. commit changes first" && exit 1)
@git checkout master && git rebase dev && git push origin master && git checkout dev \
&& echo "master rebased and pushed"
to_master:
@echo $(BR)
git checkout master && git rebase $(BR) && git checkout $(BR)
build:
docker build -t band-base-ts .
push-latest:
docker tag band-base-ts rockstat/band-base-ts:latest
docker push rockstat/band-base-ts:latest
push-dev:
docker tag band-base-ts rockstat/band-base-ts:dev
docker push rockstat/band-base-ts:dev
push:
git push origin master
git push origin dev
travis-trigger:
curl -vv -s -X POST \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-H "Travis-API-Version: 3" \
-H "Authorization: token $$TRAVIS_TOKEN" \
-d '{ "request": { "branch":"$(br)" }}' \
https://api.travis-ci.com/repo/$(subst $(DEL),$(PERCENT)2F,$(repo))/requests