From 9eb68a1d7efd40b3e42148eb7e15e53de7bcb3c5 Mon Sep 17 00:00:00 2001 From: Djeeberjr Date: Tue, 17 May 2022 01:55:32 +0200 Subject: [PATCH] improved Makefile --- Makefile | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 0546a38..a13f5aa 100644 --- a/Makefile +++ b/Makefile @@ -5,13 +5,19 @@ BUILD_DIR = build all: clean deps build .PHONY:build -build: $(BUILD_DIR)/$(BINARY) $(BUILD_DIR)/public +build: go js + +.PHONY: js +js: $(BUILD_DIR)/public + +.PHONY: go +go: $(BUILD_DIR)/$(BINARY) $(BUILD_DIR)/$(BINARY): go build -o $(BUILD_DIR)/$(BINARY) cmd/s3share.go $(BUILD_DIR)/public: - npm run build && cp -r public/ $(BUILD_DIR)/public + npm run build && mkdir -p $(BUILD_DIR) &&cp -r public/ $(BUILD_DIR)/public .PHONY: deps deps: node_modules