From 2c9c36d8327c9cadd71b4c7632f0f9f3dbc770dd Mon Sep 17 00:00:00 2001 From: leo Date: Mon, 29 Jul 2024 10:23:29 +0800 Subject: [PATCH] enhance: support character '/' in tag name (#290) --- src/ViewModels/CreateTag.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ViewModels/CreateTag.cs b/src/ViewModels/CreateTag.cs index 0a7d7440..498218cb 100644 --- a/src/ViewModels/CreateTag.cs +++ b/src/ViewModels/CreateTag.cs @@ -12,7 +12,7 @@ namespace SourceGit.ViewModels } [Required(ErrorMessage = "Tag name is required!")] - [RegularExpression(@"^[\w\-\.]+$", ErrorMessage = "Bad tag name format!")] + [RegularExpression(@"^[^/]{1}[\w\-\./]*$", ErrorMessage = "Bad tag name format!")] [CustomValidation(typeof(CreateTag), nameof(ValidateTagName))] public string TagName {