From 65a9406c9ac1cf45f7d9ab17d3d359b414ebf942 Mon Sep 17 00:00:00 2001 From: GadflyFang Date: Thu, 6 Feb 2025 10:55:07 +0800 Subject: [PATCH] fix: adjust SHA regex pattern to min 6 chars (#944) - Adjust the SHA regex pattern to match commit hashes with a minimum length of 6 characters instead of 10. --- src/Views/CommitMessagePresenter.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Views/CommitMessagePresenter.cs b/src/Views/CommitMessagePresenter.cs index a6eee1b3..dc8a3bb7 100644 --- a/src/Views/CommitMessagePresenter.cs +++ b/src/Views/CommitMessagePresenter.cs @@ -15,7 +15,7 @@ namespace SourceGit.Views { public partial class CommitMessagePresenter : SelectableTextBlock { - [GeneratedRegex(@"\b([0-9a-fA-F]{10,40})\b")] + [GeneratedRegex(@"\b([0-9a-fA-F]{6,40})\b")] private static partial Regex REG_SHA_FORMAT(); public static readonly StyledProperty MessageProperty =