-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
51 lines (36 loc) · 1.16 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
APPNAME = "phone-number"
VERSION = "8.13.6-3"
.PHONY: watch default docs deploy test test-clj sig jar pom clean tag
default: docs
lint:
bin/lint
docs:
bin/docs "$(VERSION)"
push-docs:
git subtree push --prefix=docs docs master
test-clj:
bin/test --no-profiling
test:
@$(MAKE) test-clj
pom: pom.xml
clojure -Spom && awk 'NF > 0' pom.xml > pom.new.xml && mv -f pom.new.xml pom.xml
mvn versions:set versions:commit -DnewVersion="$(VERSION)" versions:set-scm-tag -DnewTag="$(VERSION)"
rm -f pom.xml.asc
$(APPNAME).jar: pom.xml
bin/build
jar: $(APPNAME).jar
sig: pom.xml
rm -f pom.xml.asc
gpg2 --armor --detach-sig pom.xml
tag: pom.xml
git tag -s "$(VERSION)" -m "Release $(VERSION)"
deploy:
@$(MAKE) clean
@$(MAKE) pom
@$(MAKE) jar
mvn gpg:sign-and-deploy-file -Dfile=$(APPNAME).jar -DrepositoryId=clojars -Durl=https://clojars.org/repo -DpomFile=pom.xml
clean:
rm -f $(APPNAME).jar pom.xml.asc
.PHONY: list
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