We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3e42b8c commit db0e226Copy full SHA for db0e226
internal/url/url.go
@@ -6,7 +6,7 @@ import (
6
7
var (
8
isSchemeRegExp = regexp.MustCompile(`^[^:]+://`)
9
- scpLikeUrlRegExp = regexp.MustCompile(`^(?:(?P<user>[^@]+)@)?(?P<host>[^:\s]+):(?:(?P<port>[0-9]{1,5})/)?(?P<path>[^\\].*)$`)
+ scpLikeUrlRegExp = regexp.MustCompile(`^(?:(?P<user>[^@]+)@)?(?P<host>[^:\s]+):(?:(?P<port>[0-9]{1,5})(?:\/|:))?(?P<path>[^\\].*\/[^\\].*)$`)
10
)
11
12
// MatchesScheme returns true if the given string matches a URL-like
0 commit comments