Skip directories when moving build release artefacts in drone
This commit is contained in:
parent
471d1b0ec5
commit
78b261e440
1 changed files with 5 additions and 0 deletions
|
@ -474,6 +474,11 @@ func runXgo(targets string) error {
|
||||||
RootPath)
|
RootPath)
|
||||||
if os.Getenv("DRONE_WORKSPACE") != "" {
|
if os.Getenv("DRONE_WORKSPACE") != "" {
|
||||||
return filepath.Walk("/build/", func(path string, info os.FileInfo, err error) error {
|
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())
|
return os.Rename(path, RootPath+"/"+DIST+"/binaries/"+info.Name())
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue