PowerShell / PSScriptAnalyzer

Download ScriptAnalyzer from PowerShellGallery
https://www.powershellgallery.com/packages/PSScriptAnalyzer/
MIT License
1.87k stars 379 forks source link

Setting file keys are not matching cmdlet parameters exactly #1025

Open bergmeister opened 6 years ago

bergmeister commented 6 years ago

Raised due to this comment:

Invoke-ScriptAnalyzer has parameters IncludeRule and ExcludeRule parameters and the equivalent of those in the settings file are IncludeRules and ExcludeRules with an additional s, which makes it inconsistent, confusing and not intuitive to work with. The settings file also needs to support the singular form (since the plural form should not be removed for backcompat reasons)

Environment data

> (Get-Module -ListAvailable PSScriptAnalyzer).Version | ForEach-Object { $_.ToString() }
1.17.1
Halkcyon commented 6 years ago

Documentation on the -Settings parameter object in general would be greatly appreciated. It's been an increasingly frustrating experience of trial and error figuring out how the different keys/values interact especially when trying to customize formatting rules, custom rules, et al in vscode when I don't have time to dig through the source code for everything.