-
Notifications
You must be signed in to change notification settings - Fork 9
/
Makefile
62 lines (51 loc) · 1.13 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
SCRIPTS_DIR := scripts
UI := ui
.PHONY: build
build: install
daml build
daml codegen js
./$(SCRIPTS_DIR)/build.sh
# cd $(UI) && npm run build
.PHONY: install
install:
./$(SCRIPTS_DIR)/get-dependencies.sh daml.yaml
cd $(UI) && npm install
.PHONY: clean
clean:
daml clean
./$(SCRIPTS_DIR)/remove-dependencies.sh daml.yaml
cd $(SCRIPTS_DIR) && ./clean.sh
rm -rf $(UI)/node_modules
rm -rf $(UI)/daml.js
rm -rf $(UI)/build
.PHONY: test
test: build
daml test
.PHONY: headers-check
headers-check:
./$(SCRIPTS_DIR)/dade-copyright-headers.py check
.PHONY: headers-update
headers-update:
./$(SCRIPTS_DIR)/dade-copyright-headers.py update
##################################
# CI #
# - utilises nix #
# - avoids unnecessary rebuilds #
##################################
.PHONY: ci-build
ci-build:
@nix-shell \
--pure \
--run 'make build'
.PHONY: ci-test
ci-test:
@nix-shell \
--pure \
--run 'daml test'
.PHONY: ci-headers-check
ci-headers-check:
@nix-shell \
--pure \
--run './scripts/dade-copyright-headers.py check'
.PHONY: ci-local
ci-local: clean ci-headers-check ci-build ci-test