This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
|CommandsToTraverse|By default, this command will not consider child scopes other than scriptblocks provided to Where-Object or ForEach-Object. This setting allows you to add additional commands that accept scriptblocks that this rule should traverse into.|string[]: list of commands whose scriptblock to traverse.|`@('Invoke-PSFProtectedCommand')`|
By default, this rule doesn't consider child scopes other than scriptblocks provided to
`Where-Object` or `ForEach-Object`. The `CommandsToTraverse` setting is an string array allows you
to add additional commands that accept scriptblocks that this rule should examine.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- [Everything you wanted to know about ShouldProcess](https://learn.microsoft.com/powershell/scripting/learn/deep-dives/everything-about-shouldprocess)
- [about_Functions_Advanced_Methods][01]
- [about_Functions_CmdletBindingAttribute][02]
- [Everything you wanted to know about ShouldProcess][03]
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@@ -15,10 +15,9 @@ All cmdlets must used approved verbs.
Approved verbs can be found by running the command `Get-Verb`.
Additional documentation on approved verbs can be found at
[Approved Verbs for PowerShell Commands](https://learn.microsoft.com/powershell/scripting/developer/cmdlet/approved-verbs-for-windows-powershell-commands).
Some unapproved verbs are documented on the approved verbs page and point to approved alternatives.
Try searching for the verb you used to find its approved form. For example, searching for `Read`,
For a more information about approved verbs, see [Approved Verbs for PowerShell Commands][01]. Some
unapproved verbs are documented on the approved verbs page and point to approved alternatives. Try
searching for the verb you used to find its approved form. For example, searching for `Read`,
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PowerShell team best practices state cmdlets should use singular nouns and not plurals.
Suppression allows to suppress just specific function names, for example
PowerShell team best practices state cmdlets should use singular nouns and not plurals. Suppression
allows you to suppress the rule for specific function names. For example:
```
function Get-Elements {
Expand All
@@ -35,13 +34,14 @@ Rules = @{
### Parameters
#### `UseSingularNouns: string[]` (Default value is `{'Data', 'Windows'}`)
- `UseSingularNouns`: `string[]` (Default value is `{'Data', 'Windows'}`)
Commands to be excluded from this rule. `Data` and `Windows` are common false positives and are excluded by default
Commands to be excluded from this rule. `Data` and `Windows` are common false positives and are
excluded by default.
#### Enable: `bool` (Default value is `$true`)
- `Enable`: `bool` (Default value is `$true`)
Enable or disable the rule during ScriptAnalyzer invocation.
Enable or disable the rule during ScriptAnalyzer invocation.
## How
Expand Down
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Sync rule docs changes #1985
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Uh oh!
There was an error while loading. Please reload this page.
Sync rule docs changes #1985
Filter by extension
Viewed files
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
There are no files selected for viewing