From 151522def29e820b2c24f04b48b27490b18141b3 Mon Sep 17 00:00:00 2001 From: alimy Date: Tue, 31 May 2022 23:13:40 +0800 Subject: [PATCH] just make run to simple start server --- Makefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 0c3a847f..e41ed00b 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -.PHONY: all build clean fmt help +.PHONY: all build run clean fmt help BUILD_VERSION := $(shell cat version) BUILD_DATE := $(shell date +'%Y-%m-%d %H:%M:%S') SHA_SHORT := $(shell git rev-parse --short HEAD) @@ -7,6 +7,8 @@ build: @go mod download @echo Build paopao-ce bash build.sh paopao-ce +run: + @go run -ldflags "-X 'main.version=${BUILD_VERSION}' -X 'main.buildDate=${BUILD_DATE}' -X 'main.commitID=${SHA_SHORT}'" . clean: @go clean @find ./dist -type f -exec rm -r {} +