summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDan Davison <dandavison7@gmail.com>2023-08-13 17:26:10 -0400
committerGitHub <noreply@github.com>2023-08-13 17:26:10 -0400
commitf82e00dee3491f1da333f44a35fbbebb5940128b (patch)
tree01021b8b3416725fdba4e03c65dffba030172326
parentae26b5497cc5f7b958d7fa2683c0ebd002109c54 (diff)
Support users other than git in github SSH URLs (#1509)
E.g. org-123456@github.com:temporalio/api.git
-rw-r--r--src/git_config/remote.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/git_config/remote.rs b/src/git_config/remote.rs
index b4053e7b..ed60e8ad 100644
--- a/src/git_config/remote.rs
+++ b/src/git_config/remote.rs
@@ -37,7 +37,7 @@ lazy_static! {
static ref GITHUB_REMOTE_URL: Regex = Regex::new(
r"(?x)
^
- (?:https://|git@)? # Support both HTTPS and SSH URLs, SSH URLs optionally omitting the git@
+ (?:https://|[^@]+@)? # Support both HTTPS and SSH URLs
github\.com
[:/] # This separator differs between SSH and HTTPS URLs
([^/]+) # Capture the user/org name