Added variable versiontag to doxyfile

This commit is contained in:
Jeroen De Meerleer 2019-06-20 11:50:42 +02:00
parent c67715af54
commit 530f13ec30
Signed by: JeroenED
GPG Key ID: 28CCCB8F62BFADD6
2 changed files with 5 additions and 3 deletions

View File

@ -38,7 +38,7 @@ PROJECT_NAME = libpairtwo
# could be handy for archiving the generated documentation or if some version # could be handy for archiving the generated documentation or if some version
# control system is used. # control system is used.
PROJECT_NUMBER = v1.1 PROJECT_NUMBER = $(VERSIONTAG)
# Using the PROJECT_BRIEF tag one can provide an optional one line description # Using the PROJECT_BRIEF tag one can provide an optional one line description
# for a project that appears at the top of each page and should give viewer a # for a project that appears at the top of each page and should give viewer a

View File

@ -1,5 +1,7 @@
.PHONY: help tests dist .PHONY: help tests dist
.DEFAULT_GOAL := help .DEFAULT_GOAL := help
BRANCH := $(shell git rev-parse --abbrev-ref HEAD)
VERSION := $(if $(VERSION),$(VERSION),$(BRANCH))
help: help:
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-12s\033[0m %s\n", $$1, $$2}' @grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-12s\033[0m %s\n", $$1, $$2}'
@ -14,7 +16,7 @@ view-coverage: ## Shows the code coverage report
open build/coverage/index.html open build/coverage/index.html
api: ## Generates api-docs api: ## Generates api-docs
doxygen VERSIONTAG=$(VERSION) doxygen
dist: ## Generates distribution dist: ## Generates distribution
touch .libpairtwo-dist touch .libpairtwo-dist
@ -26,7 +28,7 @@ dist: ## Generates distribution
rm dist/composer.json rm dist/composer.json
rm dist/composer.lock rm dist/composer.lock
mv dist/composer-dist-installed.json dist/composer.json mv dist/composer-dist-installed.json dist/composer.json
doxygen VERSIONTAG=$(VERSION) doxygen
mkdir -p dist/doc mkdir -p dist/doc
cp -r doc/api dist/doc cp -r doc/api dist/doc
cd dist && zip -r ../libpairtwo-dist * cd dist && zip -r ../libpairtwo-dist *