Skip to content

Commit

Permalink
Clean up
Browse files Browse the repository at this point in the history
  • Loading branch information
ErikEJ committed Sep 30, 2024
1 parent 0e12bd2 commit e5acb95
Showing 1 changed file with 1 addition and 13 deletions.
14 changes: 1 addition & 13 deletions src/DacpacTool/PackageAnalyzer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -36,12 +36,11 @@ public void Analyze(TSqlModel model, FileInfo outputFile, FileInfo[] analyzers)

if (analyzers.Length == 0)
{
// warning SR0016: Microsoft.Rules.Data : Stored procedure(sp_Test) includes sp_ prefix in its name.
_console.WriteLine("DacpacTool warning SQLPROJ0001: No additional rules files found, consider adding more rules via PackageReference - see the readme here: https://github.com/rr-wfm/MSBuild.Sdk.SqlProj.");
}
else
{
_console.WriteLine("Loading analyzers: " + string.Join(", ", analyzers.Select(a => a.FullName)));
_console.WriteLine("Using additional analyzers: " + string.Join(", ", analyzers.Select(a => a.FullName)));
settings.AssemblyLookupPath = string.Join(';', analyzers.Select(a => a.DirectoryName));
}

Expand Down Expand Up @@ -122,16 +121,5 @@ private static string GetOutputFileName(FileInfo outputFile)
}
return outputFileName + ".CodeAnalysis.xml";
}

private void CopyAdditionalRulesFile(FileInfo rulesFile)
{
var destPath = Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location);

var dest = Path.Combine(destPath, rulesFile.Name);

rulesFile.CopyTo(dest, overwrite: true);

_console.WriteLine($"Adding additional rules file from '{rulesFile.FullName}' to '{dest}'");
}
}
}

0 comments on commit e5acb95

Please sign in to comment.