From e6aff8e5d6a063e3bd20f4e48d3f9e01c5591986 Mon Sep 17 00:00:00 2001 From: Maximilian Bosch Date: Fri, 6 Feb 2026 15:15:59 +0100 Subject: [PATCH] gerrit_project: allow slashes in repo path of gerrit remote Otherwise, remote URLs such as `ssh://ma27@cl.afnix.fr:2022/rokc/rokc` are rejected by this tool. --- src/gerrit_project.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/gerrit_project.rs b/src/gerrit_project.rs index 5089db6..85b31b1 100644 --- a/src/gerrit_project.rs +++ b/src/gerrit_project.rs @@ -33,7 +33,7 @@ impl GerritProject { : (?P[0-9]+) / - (?P[[:word:].-]+) + (?P[[:word:]./-]+) $", ) .expect("Regex parses") @@ -86,7 +86,7 @@ mod tests { #[test] fn test_gerrit_parse_remote_url() { assert_eq!( - GerritProject::parse_from_remote_url("ssh://rbt@ooga.booga.systems:2022/ouppy") + GerritProject::parse_from_remote_url("ssh://rbt@ooga.booga.systems:2022/ouppy/abc") .unwrap(), GerritProject { host: GerritHost { @@ -94,7 +94,7 @@ mod tests { host: "ooga.booga.systems".to_owned(), port: 2022, }, - project: "ouppy".to_owned(), + project: "ouppy/abc".to_owned(), } ); }