From 2ebd6fdbe46d15aa1cfa79d340772e7a624409a0 Mon Sep 17 00:00:00 2001 From: Victor Vazquez Date: Wed, 28 Aug 2024 17:40:25 +0000 Subject: [PATCH] allow a hostname without a .xxx suffix. This will allow hostname alias like `foo` to be a valid hostname --- cli/azd/pkg/pipeline/github_provider.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cli/azd/pkg/pipeline/github_provider.go b/cli/azd/pkg/pipeline/github_provider.go index 60886f31a16..12a84a0e99d 100644 --- a/cli/azd/pkg/pipeline/github_provider.go +++ b/cli/azd/pkg/pipeline/github_provider.go @@ -132,7 +132,7 @@ func (p *GitHubScmProvider) configureGitRemote( } // defines the structure of an ssl git remote -var gitHubRemoteGitUrlRegex = regexp.MustCompile(`^git@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}:(.*?)(?:\.git)?$`) +var gitHubRemoteGitUrlRegex = regexp.MustCompile(`^git@[a-zA-Z0-9.-_]+:(.*?)(?:\.git)?$`) // defines the structure of an HTTPS git remote var gitHubRemoteHttpsUrlRegex = regexp.MustCompile(`^https://(?:www\.)?[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}/(.*?)(?:\.git)?$`)