diff options
author | Ignacio Roldán Etcheverry <neikeq@users.noreply.github.com> | 2020-05-10 13:33:03 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-05-10 13:33:03 +0200 |
commit | 54b20a25b90c8c8d8dfd7f68d66d0ec57c71435f (patch) | |
tree | ed0fd3e030e6f65568f664bc9f5d2bb028f37618 /modules/mono/editor/GodotTools/GodotTools.ProjectEditor/ProjectExtensions.cs | |
parent | da898c116c0b45ff0dc16e80800f8694339cd4f1 (diff) | |
parent | 3ce09246d10a267bf00ae8bf37068ec458c69287 (diff) |
Merge pull request #38600 from neikeq/no
Switch to nuget Microsoft.Build and rewrite GodotTools messasing protocol
Diffstat (limited to 'modules/mono/editor/GodotTools/GodotTools.ProjectEditor/ProjectExtensions.cs')
-rw-r--r-- | modules/mono/editor/GodotTools/GodotTools.ProjectEditor/ProjectExtensions.cs | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/modules/mono/editor/GodotTools/GodotTools.ProjectEditor/ProjectExtensions.cs b/modules/mono/editor/GodotTools/GodotTools.ProjectEditor/ProjectExtensions.cs index f0e0d1b33d..704f2ec194 100644 --- a/modules/mono/editor/GodotTools/GodotTools.ProjectEditor/ProjectExtensions.cs +++ b/modules/mono/editor/GodotTools/GodotTools.ProjectEditor/ProjectExtensions.cs @@ -2,8 +2,8 @@ using GodotTools.Core; using System; using System.Collections.Generic; using System.IO; -using DotNet.Globbing; using Microsoft.Build.Construction; +using Microsoft.Build.Globbing; namespace GodotTools.ProjectEditor { @@ -11,8 +11,6 @@ namespace GodotTools.ProjectEditor { public static ProjectItemElement FindItemOrNull(this ProjectRootElement root, string itemType, string include, bool noCondition = false) { - GlobOptions globOptions = new GlobOptions {Evaluation = {CaseInsensitive = false}}; - string normalizedInclude = include.NormalizePath(); foreach (var itemGroup in root.ItemGroups) @@ -25,7 +23,8 @@ namespace GodotTools.ProjectEditor if (item.ItemType != itemType) continue; - var glob = Glob.Parse(item.Include.NormalizePath(), globOptions); + //var glob = Glob.Parse(item.Include.NormalizePath(), globOptions); + var glob = MSBuildGlob.Parse(item.Include.NormalizePath()); if (glob.IsMatch(normalizedInclude)) return item; @@ -36,8 +35,6 @@ namespace GodotTools.ProjectEditor } public static ProjectItemElement FindItemOrNullAbs(this ProjectRootElement root, string itemType, string include, bool noCondition = false) { - GlobOptions globOptions = new GlobOptions {Evaluation = {CaseInsensitive = false}}; - string normalizedInclude = Path.GetFullPath(include).NormalizePath(); foreach (var itemGroup in root.ItemGroups) @@ -50,7 +47,7 @@ namespace GodotTools.ProjectEditor if (item.ItemType != itemType) continue; - var glob = Glob.Parse(Path.GetFullPath(item.Include).NormalizePath(), globOptions); + var glob = MSBuildGlob.Parse(Path.GetFullPath(item.Include).NormalizePath()); if (glob.IsMatch(normalizedInclude)) return item; |