From 3ce7703d606b9873d5e8c4e4fd3306da06e2b69e Mon Sep 17 00:00:00 2001 From: Ning Shang Date: Mon, 17 Oct 2022 14:50:43 -0700 Subject: [PATCH] Make `make clean` output cleaner Use `rm -f` to suppress errors on removal of nonexistent files. Also make `clean` a phony target. --- Makefile | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/Makefile b/Makefile index 9b5bae3..f67cc1d 100755 --- a/Makefile +++ b/Makefile @@ -64,11 +64,12 @@ build-all: build ${NOCGO} GOOS=windows GOARCH=amd64 go build ${FLAGS} -o builds/gossa-windows.exe sha256sum builds/* +.PHONY: clean clean: - -rm gossa - -rm gossa-linux64 - -rm gossa-linux-arm - -rm gossa-linux-arm64 - -rm gossa-mac - -rm gossa-windows.exe + rm -f gossa + rm -f gossa-linux64 + rm -f gossa-linux-arm + rm -f gossa-linux-arm64 + rm -f gossa-mac + rm -f gossa-windows.exe