diff --git a/Makefile b/Makefile index 50691e7..f09e1b0 100644 --- a/Makefile +++ b/Makefile @@ -1,14 +1,14 @@ # Custom configuration | 独立配置 # Service name | 项目名称 -SERVICE=mini-chat +SERVICE=minichat # Service name in specific style | 项目经过style格式化的名称 -SERVICE_STYLE=mini-chat +SERVICE_STYLE=minichat # Service name in lowercase | 项目名称全小写格式 -SERVICE_LOWER=mini-chat +SERVICE_LOWER=minichat # Service name in snake format | 项目名称下划线格式 -SERVICE_SNAKE=mini_chat +SERVICE_SNAKE=minichat # Service name in snake format | 项目名称短杠格式 -SERVICE_DASH=mini-chat +SERVICE_DASH=minichat # The project version, if you don't use git, you should set it manually | 项目版本,如果不使用git请手动设置 VERSION=$(shell git describe --tags --always) @@ -93,17 +93,17 @@ gen-api: # Generate API files | 生成 API 的代码 .PHONY: build-win build-win: # Build project for Windows | 构建Windows下的可执行文件 - env CGO_ENABLED=0 GOOS=windows go build -ldflags "$(LDFLAGS)" -o $(SERVICE_STYLE)_$(PROJECT_BUILD_SUFFIX).exe $(SERVICE_STYLE).go + env CGO_ENABLED=0 GOOS=windows go build -ldflags "$(LDFLAGS)" -o $(SERVICE_STYLE)_$(PROJECT_BUILD_SUFFIX).exe main.go @echo "Build project for Windows successfully" .PHONY: build-mac build-mac: # Build project for MacOS | 构建MacOS下的可执行文件 - env CGO_ENABLED=0 GOOS=darwin go build -ldflags "$(LDFLAGS)" -o $(SERVICE_STYLE)_$(PROJECT_BUILD_SUFFIX) $(SERVICE_STYLE).go + env CGO_ENABLED=0 GOOS=darwin go build -ldflags "$(LDFLAGS)" -o $(SERVICE_STYLE)_$(PROJECT_BUILD_SUFFIX) main.go @echo "Build project for MacOS successfully" .PHONY: build-linux build-linux: # Build project for Linux | 构建Linux下的可执行文件 - env CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags "$(LDFLAGS)" -o $(SERVICE_STYLE)_$(PROJECT_BUILD_SUFFIX) $(SERVICE_STYLE).go + env CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags "$(LDFLAGS)" -o $(SERVICE_STYLE)_$(PROJECT_BUILD_SUFFIX) main.go @echo "Build project for Linux successfully" .PHONY: proto2api