File tree Expand file tree Collapse file tree 2 files changed +21
-2
lines changed Expand file tree Collapse file tree 2 files changed +21
-2
lines changed Original file line number Diff line number Diff line change @@ -12,15 +12,15 @@ before_script:
1212
1313before_install :
1414 - docker pull vbatts/pandoc
15- - go get github.com/vbatts/git-validation
15+ - make install.tools
1616 - go get github.com/alecthomas/gometalinter
1717 - gometalinter --install --update
1818 - go get -t -d ./...
1919
2020install : true
2121
2222script :
23- - git-validation -run DCO,short-subject -v -range ${TRAVIS_COMMIT_RANGE}
23+ - make .gitvalidation
2424 - make lint
2525 - make check-license
2626 - make test
Original file line number Diff line number Diff line change @@ -15,6 +15,8 @@ FIGURE_FILES := \
1515OUTPUT ?= output/
1616DOC_FILENAME ?= oci-image-spec
1717
18+ EPOCH_TEST_COMMIT ?= v0.2.0
19+
1820default : help
1921
2022help :
8284img/% .png : % .dot
8385 dot -Tpng $^ > $@
8486
87+ .PHONY : .gitvalidation
88+
89+ # When this is running in travis, it will only check the travis commit range
90+ .gitvalidation :
91+ @which git-validation > /dev/null 2> /dev/null || (echo " ERROR: git-validation not found. Consider 'make install.tools' target" && false)
92+ ifeq ($(TRAVIS ) ,true)
93+ git-validation -q -run DCO,short-subject,dangling-whitespace
94+ else
95+ git-validation -v -run DCO,short-subject,dangling-whitespace -range $(EPOCH_TEST_COMMIT)..HEAD
96+ endif
97+
98+ .PHONY : install.tools
99+ install.tools : .install.gitvalidation
100+
101+ .install.gitvalidation :
102+ go get github.com/vbatts/git-validation
103+
85104clean :
86105 rm -rf * ~ $(OUTPUT )
87106.PHONY : \
You can’t perform that action at this time.
0 commit comments