Skip to content

Commit 9a2bd36

Browse files
committed
Added 3 dev makefiles, use make dev on root to build and yarn libs/clients
1 parent 979dbe0 commit 9a2bd36

3 files changed

Lines changed: 25 additions & 4 deletions

File tree

Makefile

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
.PHONY: dev
2+
3+
dev:
4+
@echo "---Building libs---"
5+
@(cd $(CURDIR)/lib && make dev) || (echo "Failed to build libs"; exit 1)
6+
@echo "---Yarning clients---"
7+
@(cd $(CURDIR)/client && make yarn) || (echo "Failed to yarn clients"; exit 1)
8+
9+
.DEFAULT_GOAL := dev

client/Makefile

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,11 @@
1-
WEB_SUBDIRS := $(filter %/, $(wildcard web/*/))
1+
WEB_SUBDIRS := $(filter %/, $(wildcard $(CURDIR)/web/*/))
22

33
.PHONY: yarn
44

55
yarn:
66
@for dir in $(WEB_SUBDIRS); do \
7-
echo "Entering $$dir"; \
8-
cd $$dir && yarn; \
9-
cd ../..; \
7+
echo "---Yarning $$dir---"; \
8+
(cd $$dir && yarn) || (echo "Failed to yarn $$dir"; exit 1); \
109
done
1110

1211
.DEFAULT_GOAL := yarn

lib/Makefile

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
LIB_SUBDIRS := $(filter %/, $(wildcard */))
2+
3+
.PHONY: build dev
4+
5+
build:
6+
@echo "---Building js---"
7+
@(cd $(CURDIR)/js && yarn && yarn build) || (echo "Failed to build js"; exit 1)
8+
@echo "---Building vue---"
9+
@(cd $(CURDIR)/vue && yarn && yarn build) || (echo "Failed to build vue"; exit 1)
10+
11+
dev: build
12+
13+
.DEFAULT_GOAL := dev

0 commit comments

Comments
 (0)