Skip to content

Commit 68c8c4e

Browse files
authored
Fix tilde paths (#1801)
1 parent 4abf839 commit 68c8c4e

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

pkg/remote/connparse/connparse.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ func ParseURI(uri string) (*Connection, error) {
132132
}
133133
if strings.HasPrefix(remotePath, "/~") {
134134
remotePath = strings.TrimPrefix(remotePath, "/")
135-
} else if len(remotePath) > 1 && !windowsDriveRegex.MatchString(remotePath) && !strings.HasPrefix(remotePath, "/") {
135+
} else if len(remotePath) > 1 && !windowsDriveRegex.MatchString(remotePath) && !strings.HasPrefix(remotePath, "/") && !strings.HasPrefix(remotePath, "~") {
136136
remotePath = "/" + remotePath
137137
}
138138
}

0 commit comments

Comments
 (0)