diff --git a/cmd/kratos/internal/base/vcs_url.go b/cmd/kratos/internal/base/vcs_url.go index ef76db30f..6d3aef12a 100644 --- a/cmd/kratos/internal/base/vcs_url.go +++ b/cmd/kratos/internal/base/vcs_url.go @@ -8,7 +8,7 @@ import ( ) var ( - scpSyntaxRe = regexp.MustCompile(`^([a-zA-Z0-9_]+)@([a-zA-Z0-9._-]+):(.*)$`) + scpSyntaxRe = regexp.MustCompile(`^(\w+)@([\w.-]+):(.*)$`) scheme = []string{"git", "https", "http", "git+ssh", "ssh", "file", "ftp", "ftps"} )