forked from HewlettPackard/py-spiffe
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
69 lines (55 loc) · 1.51 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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
# Root Makefile for managing spiffe modules
# Define module directories
CORE_DIR=./spiffe
TLS_DIR=./spiffe-tls
.DEFAULT_GOAL := help
.PHONY: all
all: lint build test
.PHONY: deps
deps:
@echo "Installing dependencies for all modules..."
cd $(CORE_DIR) && $(MAKE) deps
cd $(TLS_DIR) && $(MAKE) deps
.PHONY: build
build: deps
@echo "Building all modules..."
cd $(CORE_DIR) && $(MAKE) build
cd $(TLS_DIR) && $(MAKE) build
.PHONY: test
test:
@echo "Running tests for all modules..."
cd $(CORE_DIR) && $(MAKE) test
cd $(TLS_DIR) && $(MAKE) test
.PHONY: integration
integration:
@echo "Running integration tests for all modules..."
cd $(CORE_DIR) && $(MAKE) integration
cd $(TLS_DIR) && $(MAKE) integration
.PHONY: format
format:
@echo "Formatting all modules..."
cd $(CORE_DIR) && $(MAKE) format
cd $(TLS_DIR) && $(MAKE) format
.PHONY: lint
lint: format
@echo "Linting all modules..."
cd $(CORE_DIR) && $(MAKE) lint
cd $(TLS_DIR) && $(MAKE) lint
.PHONY: pre-commit ## Prepare files for commit.
pre-commit: copyright lint
.PHONY: copyright
copyright:
@echo "Adding copyright header to files..."
python scripts/copyright.py
# Display help for the root Makefile
help:
@echo "Usage:"
@echo " make <target>"
@echo ""
@echo "Targets:"
@echo " deps Install dependencies for all modules"
@echo " build Build all modules"
@echo " test Run tests for all modules"
@echo " lint Lint all modules"
@echo " format Format all modules"
@echo " help Display this help message"