Skip to content

Commit

Permalink
feat: support .editorconfig for analyzer
Browse files Browse the repository at this point in the history
  • Loading branch information
mob-sakai committed Nov 16, 2020
1 parent 9f7334b commit 0e1d4c3
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions Plugins/CSharpCompilerSettings/Core.cs
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,16 @@ private static void ChangeCompilerProcess(object compiler, object scriptAssembly

foreach (var ruleset in rulesets)
text += string.Format("\n/ruleset:\"{0}\"", ruleset);

// Editor Config.
var configs = new[]
{
".editorconfig",
Utils.PathCombine(asmdefDir ?? "Assets", ".editorconfig")
}
.Where(File.Exists);
foreach (var config in configs)
text += string.Format("\n/analyzerconfig:\"{0}\"", config);
}

// Replace NewLine and save.
Expand Down

0 comments on commit 0e1d4c3

Please sign in to comment.