From ef72597fb92dc97a8ca746e630d5a238550f381f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B0=A2=E5=B0=8F=E5=86=9B?= <346944475@qq.com> Date: Wed, 19 Aug 2020 17:16:54 +0800 Subject: [PATCH] update makefile MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 更新makefile定义 --- Makefile | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/Makefile b/Makefile index 534ed02..b5dea47 100644 --- a/Makefile +++ b/Makefile @@ -14,10 +14,11 @@ tar: # 打包 CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o gormt main.go tar czvf gormt_linux.zip gormt config.yml clear: - - rm -rf model/* - - rm -rf err/ - - rm gormt - - rm gormt.exe - - rm gormt_linux.zip - - rm gormt_mac.zip - - rm gormt_windows.zip + test ! -d model/ || rm -rf model/* + test ! -d err/ || rm -rf err/ + test ! -f gormt || rm gormt + test ! -f gormt.exe || rm gormt.exe + test ! -f gormt_linux.zip || rm gormt_linux.zip + test ! -f gormt_mac.zip || rm gormt_mac.zip + test ! -f gormt_windows.zip || rm gormt_windows.zip + \ No newline at end of file