From 6af8c7bc6743cb35054ce87ac8b98686cfcde956 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=88=98=E7=A3=8A?= Date: Sun, 4 Dec 2022 18:36:11 +0800 Subject: [PATCH 1/2] =?UTF-8?q?1=E3=80=81=E6=9B=B4=E6=96=B0=E6=8E=92?= =?UTF-8?q?=E9=99=A4=E7=9B=AE=E5=BD=95=E8=BF=87=E6=BB=A4=E6=9D=A1=E4=BB=B6?= =?UTF-8?q?=EF=BC=88=E7=9B=B4=E6=8E=A5=E9=80=89C=E7=9B=98=E5=88=9B?= =?UTF-8?q?=E5=BB=BA=E7=B4=A2=E5=BC=95=E5=B4=A9=E6=BA=83=E9=97=AE=E9=A2=98?= =?UTF-8?q?=EF=BC=89=202=E3=80=81=E4=BB=A3=E7=A0=81=E5=A2=9E=E5=8A=A0.vue?= =?UTF-8?q?=E5=92=8C.md=203=E3=80=81=E9=BB=98=E8=AE=A4=E6=8E=92=E5=BA=8F?= =?UTF-8?q?=E8=A7=84=E5=88=99=E6=9B=B4=E6=94=B9=E4=B8=BALucene.Net.Search.?= =?UTF-8?q?Sort.RELEVANCE=204=E3=80=81=E7=B4=A2=E5=BC=95=E6=8E=92=E9=99=A4?= =?UTF-8?q?nodejs=E7=9A=84NODE=5FMODULES=E7=9B=AE=E5=BD=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- TextLocator/Core/AppConst.cs | 2 +- TextLocator/Enums/FileType.cs | 2 +- TextLocator/Index/IndexCore.cs | 4 +++- TextLocator/Properties/AssemblyInfo.cs | 2 +- TextLocator/Util/FileUtil.cs | 2 +- 5 files changed, 7 insertions(+), 5 deletions(-) diff --git a/TextLocator/Core/AppConst.cs b/TextLocator/Core/AppConst.cs index f6bb3c4..a79efb2 100644 --- a/TextLocator/Core/AppConst.cs +++ b/TextLocator/Core/AppConst.cs @@ -112,7 +112,7 @@ namespace TextLocator.Core /// /// 匹配排除关键词 /// - public static readonly Regex REGEX_EXCLUDE_KEYWORD = new Regex(@"(\$RECYCLE|360REC|SYSTEM|TEMP|SYSTEM VOLUME INFOMATION|\{(.*)\})"); + public static readonly Regex REGEX_EXCLUDE_KEYWORD = new Regex(@"(\:\\(Windows|Program|System|Documents|\$(360Section|RECYCLE(\.BIN|)|WinREAgent)|360(Rec|SANDBOX))|T(E|)MP|node_modules|\{(.*)\})", RegexOptions.IgnoreCase); /// /// 匹配开始字符 /// diff --git a/TextLocator/Enums/FileType.cs b/TextLocator/Enums/FileType.cs index d94aa78..7185c31 100644 --- a/TextLocator/Enums/FileType.cs +++ b/TextLocator/Enums/FileType.cs @@ -55,7 +55,7 @@ namespace TextLocator.Enums /// /// 程序员代码 /// - [Description("cs,java,js,css,md,py,c,h,cpp,lua,sql,jsp,json,php,rs,rb,yml,yaml,bat,ps1")] + [Description("cs,java,js,css,md,py,c,h,cpp,lua,sql,jsp,json,php,rs,rb,yml,yaml,bat,ps1,vue,md")] 程序员代码 } } diff --git a/TextLocator/Index/IndexCore.cs b/TextLocator/Index/IndexCore.cs index cd94471..0cbac20 100644 --- a/TextLocator/Index/IndexCore.cs +++ b/TextLocator/Index/IndexCore.cs @@ -756,7 +756,9 @@ namespace TextLocator.Index Lucene.Net.Search.Sort sort = new Lucene.Net.Search.Sort(); switch (param.SortType) { - case SortType.默认排序: break; + case SortType.默认排序: + sort = Lucene.Net.Search.Sort.RELEVANCE; + break; case SortType.从远到近: sort.SetSort(new Lucene.Net.Search.SortField("UpdateTime", Lucene.Net.Search.SortField.STRING_VAL, false)); break; diff --git a/TextLocator/Properties/AssemblyInfo.cs b/TextLocator/Properties/AssemblyInfo.cs index 263a798..db74066 100644 --- a/TextLocator/Properties/AssemblyInfo.cs +++ b/TextLocator/Properties/AssemblyInfo.cs @@ -52,7 +52,7 @@ using System.Windows; // 大版本,强制更新最小版本 [assembly: AssemblyVersion("2.1.31.0")] // 小版本,选择更新版本 -[assembly: AssemblyFileVersion("2.1.31.0")] +[assembly: AssemblyFileVersion("2.1.31.1")] // Version minVersion = System.Reflection.Assembly.GetExecutingAssembly().GetName().Version; // Version version = new Version(FileVersionInfo.GetVersionInfo(System.Windows.Forms.Application.ExecutablePath).ProductVersion); diff --git a/TextLocator/Util/FileUtil.cs b/TextLocator/Util/FileUtil.cs index 2e58db6..ba4f435 100644 --- a/TextLocator/Util/FileUtil.cs +++ b/TextLocator/Util/FileUtil.cs @@ -130,7 +130,7 @@ namespace TextLocator.Util continue; } string dirPath = dir.FullName; - // 系统过滤:$RECYCLE|360REC|SYSTEM|TEMP|SYSTEM VOLUME INFOMATION + // 系统过滤:$RECYCLE|360REC|SYSTEM|TEMP|SYSTEM VOLUME INFOMATION|NODE_MODULES // 自定义过滤: if (AppConst.REGEX_EXCLUDE_KEYWORD.IsMatch(dirPath.ToUpper())) { -- Gitee From debdb680ad857dae50a0632efb938c542766cbfa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=88=98=E7=A3=8A?= Date: Sun, 4 Dec 2022 18:40:50 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E7=89=88=E6=9C=AC=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- TextLocator/Properties/AssemblyInfo.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/TextLocator/Properties/AssemblyInfo.cs b/TextLocator/Properties/AssemblyInfo.cs index db74066..1448537 100644 --- a/TextLocator/Properties/AssemblyInfo.cs +++ b/TextLocator/Properties/AssemblyInfo.cs @@ -50,9 +50,9 @@ using System.Windows; //通过使用 "*",如下所示: // [assembly: AssemblyVersion("1.0.*")] // 大版本,强制更新最小版本 -[assembly: AssemblyVersion("2.1.31.0")] +[assembly: AssemblyVersion("2.1.32.0")] // 小版本,选择更新版本 -[assembly: AssemblyFileVersion("2.1.31.1")] +[assembly: AssemblyFileVersion("2.1.32.0")] // Version minVersion = System.Reflection.Assembly.GetExecutingAssembly().GetName().Version; // Version version = new Version(FileVersionInfo.GetVersionInfo(System.Windows.Forms.Application.ExecutablePath).ProductVersion); -- Gitee