-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
74 lines (57 loc) · 1.69 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
70
71
72
73
74
TOP_DIR=.
README=$(TOP_DIR)/README.md
VERSION=$(strip $(shell cat version))
build:
@echo "Building typescript packages..."
@cd core/types && npm run build
@cd relay/storage && npm run build
@cd relay/storage-memory && npm run build
@cd relay/storage-nedb && npm run build
@cd relay/storage-mongo && npm run build
@cd core/authenticator && npm run build
@cd core/handler && npm run build
@cd core/state && npm run build
@cd relay/adapter-express && npm run build
@cd ux/react && npm run build
bundle:
@echo "Bundling blocklets..."
@cd relay/server && npm run bundle
@cd ux/react && npm run bundle
init: install dep env
@echo "Initializing the repo..."
@make build
github-init:
@echo "Initialize software required for github (normally ubuntu software)"
@sudo npm install --unsafe-perm -g @blocklet/cli typescript
@make dep
@make build
install:
@echo "Install software required for this repo..."
@npm install -g lerna yarn @blocklet/cli typescript
dep:
@echo "Install dependencies required for this repo..."
@yarn
all: pre-build build post-build
test:
@echo "Running test suites..."
@npm run test
lint:
@echo "Linting the software..."
@npm run lint
docs:
@echo "Building and publishing the documenation..."
@npm run docs
@node scripts/collect-docs.js
@cd docs && yarn && yarn build
precommit: dep lint build test
clean:
@echo "Cleaning the build..."
@rm -rf coverage
@lerna exec --no-bail -- "rm -rf coverage .blocklet"
coverage:
@echo "Running unit tests and collecting coverage..."
@npm run coverage
run:
@echo "Running the software..."
include .makefiles/*.mk
.PHONY: build init travis-init install dep all test docs precommit travis clean watch run bump-version create-pr