Skip to content

Commit

Permalink
step_download: force copy of local files only on windows
Browse files Browse the repository at this point in the history
  • Loading branch information
azr committed Apr 29, 2019
1 parent 200e26e commit 65be2be
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions common/step_download.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import (
"fmt"
"log"
"os"
"runtime"
"strings"

"github.com/gofrs/flock"
Expand Down Expand Up @@ -93,11 +94,13 @@ var (
)

func init() {
getters["file"] = &getter.FileGetter{
// always copy local files instead of symlinking to fix GH-7534. The
// longer term fix for this would be to change the go-getter so that it
// can leave the source file where it is & tell us where it is.
Copy: true,
if runtime.GOOS == "windows" {
getters["file"] = &getter.FileGetter{
// always copy local files instead of symlinking to fix GH-7534. The
// longer term fix for this would be to change the go-getter so that it
// can leave the source file where it is & tell us where it is.
Copy: true,
}
}
}

Expand Down

0 comments on commit 65be2be

Please sign in to comment.