Open jegannathanmaniganadan opened 4 years ago
This is essentially planned for PSSA 2; rules, whether implemented by .NET classes or PS functions, should define an attribute to declare a name, with the namespace being the assembly or module name (the namespace is also customisable/overrideable)
Apologies if I am repeating something or if this has been discussed already. This is mostly an re-iteration of https://github.com/PowerShell/PSScriptAnalyzer/issues/1140#issuecomment-488251888
As of now, custom rule names are inconsistent across various places.
$MyInvocation.InvocationName
for rule/violation nameMeasure-Something
. On the other I can ship the violation with whatever name I like which has no value and can break things.<ModuleName>\<RuleName>
. That would end up something like,FooBar\Measure-Something