makefile: fix frontend app path

This commit is contained in:
c9s 2022-09-06 18:57:40 +08:00
parent 46d8d28b5b
commit 78299a6e7d
No known key found for this signature in database
GPG Key ID: 7385E7E464CB0A54

View File

@ -15,7 +15,7 @@ OSX_APP_CODESIGN_IDENTITY ?=
# OSX_APP_GUI ?= lorca
OSX_APP_GUI ?= webview
FRONTEND_EXPORT_DIR = frontend/out
FRONTEND_EXPORT_DIR = apps/frontend/out
BACKTEST_REPORT_APP_DIR = apps/backtest-report
BACKTEST_REPORT_EXPORT_DIR = apps/backtest-report/out
@ -224,13 +224,13 @@ docker-push:
docker push yoanlin/bbgo
bash -c "[[ -n $(DOCKER_TAG) ]] && docker push yoanlin/bbgo:$(DOCKER_TAG)"
frontend/node_modules:
cd frontend && yarn install
apps/frontend/node_modules:
cd apps/frontend && yarn install
frontend/out/index.html: frontend/node_modules
cd frontend && yarn export
apps/frontend/out/index.html: apps/frontend/node_modules
cd apps/frontend && yarn export
pkg/server/assets.go: frontend/out/index.html
pkg/server/assets.go: apps/frontend/out/index.html
go run ./utils/embed -package server -tag web -output $@ $(FRONTEND_EXPORT_DIR)
$(BACKTEST_REPORT_APP_DIR)/node_modules:
@ -244,7 +244,7 @@ pkg/backtest/assets.go: $(BACKTEST_REPORT_APP_DIR)/out/index.html
embed: pkg/server/assets.go pkg/backtest/assets.go
static: frontend/out/index.html pkg/server/assets.go pkg/backtest/assets.go
static: apps/frontend/out/index.html pkg/server/assets.go pkg/backtest/assets.go
PROTOS := \
$(wildcard pkg/pb/*.proto)