fix: Conventional commits: number in scope not allowed. (OD-2593)

This commit is contained in:
Robin Shen 2025-10-30 08:09:01 +08:00
parent 573cf4ebf2
commit c40ed5b998

View File

@ -51,7 +51,7 @@ public class BranchProtection implements Serializable {
private static final long serialVersionUID = 1L;
private static final Pattern CONVENTIONAL_COMMIT_SUBJECT = Pattern.compile(
"^((\\p{L}+)(\\((\\p{L}+([\\-/ ]\\p{L}+)*)\\))?!?: [^ ].+)|^(revert \".*\")",
"^((\\p{L}+)(\\(([\\p{L}\\p{N}]+([\\-/ ][\\p{L}\\p{N}]+)*)\\))?!?: [^ ].+)|^(revert \".*\")",
UNICODE_CHARACTER_CLASS | CASE_INSENSITIVE);
private boolean enabled = true;