From dcd7e6c187dde275f74b0720f1f4d318595d4acf Mon Sep 17 00:00:00 2001 From: Dominic Della Valle Date: Mon, 12 Mar 2018 10:22:26 -0400 Subject: [PATCH] Fix get output path Minor but important change for platform native output paths License: MIT Signed-off-by: Dominic Della Valle --- core/commands/get.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/core/commands/get.go b/core/commands/get.go index e8716f580..4bd6a42f7 100644 --- a/core/commands/get.go +++ b/core/commands/get.go @@ -6,7 +6,7 @@ import ( "fmt" "io" "os" - gopath "path" + "path/filepath" "strings" core "github.com/ipfs/go-ipfs/core" @@ -187,8 +187,8 @@ func getOutPath(req *cmds.Request) string { outPath, _ := req.Options["output"].(string) if outPath == "" { trimmed := strings.TrimRight(req.Arguments[0], "/") - _, outPath = gopath.Split(trimmed) - outPath = gopath.Clean(outPath) + _, outPath = filepath.Split(trimmed) + outPath = filepath.Clean(outPath) } return outPath }