forked from OpenNMS/opennms-provisioning-integration-server
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
53 lines (40 loc) · 1.15 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
52
53
##
# Makefile to build PRIS
##
.PHONY: help docs docs-docker deps-docs deps-docs-docker clean-docs clean-docs-cache clean-all
.DEFAULT_GOAL := all
SHELL := /bin/bash -o nounset -o pipefail -o errexit
WORKING_DIRECTORY := $(shell pwd)
DOCKER_ANTORA_IMAGE := antora/antora:3.1.7
SITE_FILE := antora-playbook-local.yml
deps-build:
@command -v javac
@command -v mvn
compile:
@echo "Maven validate ..."
mvn validate
@echo "Maven compile ... "
mvn compile
@echo "Maven tests ..."
mvn verify
package:
@echo "Maven package ..."
mvn package -DskipTests
deps-docs:
@command -v antora
deps-docs-docker:
@command -v docker
docs: deps-docs
@echo "Build Antora docs..."
antora --stacktrace $(SITE_FILE)
docs-docker: deps-docs-docker
@echo "Build Antora docs with docker ..."
docker run --rm -v $(WORKING_DIRECTORY):/antora $(DOCKER_ANTORA_IMAGE) --stacktrace generate $(SITE_FILE)
clean-docs:
@echo "Delete build and public artifacts ..."
@rm -rf build public
clean-docs-cache:
@echo "Clean Antora cache for git repositories and UI components ..."
@rm -rf .cache
clean-all: clean-docs clean-docs-cache
all: compile package docs