You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Following on from #246 I personally think that the default ruleset should be to include all Error & Warning Severity rules from PSScriptAnalyzer.
My reason behind this amounts to the following example
New user to PowerShell, perhaps on Windows or now on Linux
Likely to have copied someone else's script off of an online source (common scenario)
Helps them to improve script writing for use across multiple machines
However that being said I am aware of the issues with how rules are sometimes overpowering in their output within VSCode so if we can collectively agree a set of default rules then that would be a good start.
Also I've been trying to make use of the "powershell.scriptAnalysis.settingsPath" setting but this doesn't seem to be accepting any paths that I've been giving it.
The text was updated successfully, but these errors were encountered:
Try adding a file called settings.json to your .vscode folder with this content:
{
// Use a custom PowerShell Script Analyzer settings file for this workspace.
// Relative paths for this setting are always relative to the workspace root dir.
"powershell.scriptAnalysis.settingsPath": "./PSScriptAnalyzerSettings.psd1"
}
Then put a file called PSScriptAnalyzerSettings.psd1 in your workspace root folder (or under it somewhere - adjust the relative path above).
Following on from #246 I personally think that the default ruleset should be to include all Error & Warning Severity rules from PSScriptAnalyzer.
My reason behind this amounts to the following example
However that being said I am aware of the issues with how rules are sometimes overpowering in their output within VSCode so if we can collectively agree a set of default rules then that would be a good start.
Also I've been trying to make use of the "powershell.scriptAnalysis.settingsPath" setting but this doesn't seem to be accepting any paths that I've been giving it.
The text was updated successfully, but these errors were encountered: