diff --git a/Makefile b/Makefile new file mode 100644 index 000000000..7a489c832 --- /dev/null +++ b/Makefile @@ -0,0 +1,9 @@ +.PHONY: dev + +dev: + @echo "---Building libs---" + @(cd $(CURDIR)/lib && make dev) || (echo "Failed to build libs"; exit 1) + @echo "---Yarning clients---" + @(cd $(CURDIR)/client && make yarn) || (echo "Failed to yarn clients"; exit 1) + +.DEFAULT_GOAL := dev \ No newline at end of file diff --git a/client/Makefile b/client/Makefile index 488cf880f..fbade8e67 100644 --- a/client/Makefile +++ b/client/Makefile @@ -1,12 +1,11 @@ -WEB_SUBDIRS := $(filter %/, $(wildcard web/*/)) +WEB_SUBDIRS := $(filter %/, $(wildcard $(CURDIR)/web/*/)) .PHONY: yarn yarn: @for dir in $(WEB_SUBDIRS); do \ - echo "Entering $$dir"; \ - cd $$dir && yarn; \ - cd ../..; \ + echo "---Yarning $$dir---"; \ + (cd $$dir && yarn) || (echo "Failed to yarn $$dir"; exit 1); \ done .DEFAULT_GOAL := yarn \ No newline at end of file diff --git a/lib/Makefile b/lib/Makefile new file mode 100644 index 000000000..b60d1ad63 --- /dev/null +++ b/lib/Makefile @@ -0,0 +1,13 @@ +LIB_SUBDIRS := $(filter %/, $(wildcard */)) + +.PHONY: build dev + +build: + @echo "---Building js---" + @(cd $(CURDIR)/js && yarn && yarn build) || (echo "Failed to build js"; exit 1) + @echo "---Building vue---" + @(cd $(CURDIR)/vue && yarn && yarn build) || (echo "Failed to build vue"; exit 1) + +dev: build + +.DEFAULT_GOAL := dev \ No newline at end of file