[UTC] Fix git URL regex
authorHenrik G. Olsson <hnrklssn@gmail.com>
Wed, 5 Jul 2023 12:35:00 +0000 (14:35 +0200)
committerHenrik G. Olsson <hnrklssn@gmail.com>
Wed, 5 Jul 2023 12:38:02 +0000 (14:38 +0200)
The previous git URL regex only matched SSH urls, starting with 'git@'.
If the repo was cloned using a https URL it would not match.

rdar://105239218

llvm/utils/UpdateTestChecks/common.py

index b90e4f6..e2f4a14 100644 (file)
@@ -1573,7 +1573,7 @@ def filter_globals_according_to_preference(
 
 # The capture group is kept as is, followed by a {{.*}} glob
 METADATA_FILTERS = [
-    r"(\w+ version )[\d.]+ \(git@[\w.:/-]+\.git \w+\)",
+    r"(\w+ version )[\d.]+ \([\w.:/@-]+\.git \w+\)",
     r'(!DIFile\(filename: ".+", directory: )".+"',
 ]
 METADATA_FILTERS_RE = [re.compile(s) for s in METADATA_FILTERS]