From 78b261e440da87b925dd40306e128430ec0b15de Mon Sep 17 00:00:00 2001 From: kolaente Date: Thu, 3 Sep 2020 18:08:57 +0200 Subject: [PATCH] Skip directories when moving build release artefacts in drone --- magefile.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/magefile.go b/magefile.go index 86f54005..052af811 100644 --- a/magefile.go +++ b/magefile.go @@ -474,6 +474,11 @@ func runXgo(targets string) error { RootPath) if os.Getenv("DRONE_WORKSPACE") != "" { return filepath.Walk("/build/", func(path string, info os.FileInfo, err error) error { + // Skip directories + if info.IsDir() { + return nil + } + return os.Rename(path, RootPath+"/"+DIST+"/binaries/"+info.Name()) }) }