From c85068a28413848d0b6ef17b4bb8451fb05bbb3c Mon Sep 17 00:00:00 2001 From: risk danger olson Date: Fri, 10 Feb 2017 15:08:25 -0700 Subject: [PATCH] commands: trim path separator on windows too --- commands/command_lock.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/commands/command_lock.go b/commands/command_lock.go index 0a7141e7..553d7ce9 100644 --- a/commands/command_lock.go +++ b/commands/command_lock.go @@ -72,7 +72,7 @@ func lockPath(file string) (string, error) { abs := filepath.Join(wd, file) path := strings.TrimPrefix(abs, repo) - path = strings.TrimPrefix(path, "/") + path = strings.TrimPrefix(path, os.PathSeparator) if stat, err := os.Stat(abs); err != nil { return path, err } else {