Documentation Index
Fetch the complete documentation index at: https://tally.wharflab.com/llms.txt
Use this file to discover all available pages before exploring further.
powershell/PSShouldProcess is a PSScriptAnalyzer diagnostic emitted by tally for PowerShell snippets embedded in Dockerfiles.
| Property | Value |
|---|---|
| Severity | Warning |
| Category | PSScriptAnalyzer |
| Auto-fix | No |
Description
If a cmdlet declares theSupportsShouldProcess attribute, then it should also call
ShouldProcess. A violation is any function which either declares SupportsShouldProcess attribute
but makes no calls to ShouldProcess or it calls ShouldProcess but does not declare
SupportsShouldProcess.
For more information, see the following articles:
- about_Functions_Advanced_Methods
- about_Functions_CmdletBindingAttribute
- Everything you wanted to know about ShouldProcess
How
To fix a violation of this rule, please callShouldProcess method when a cmdlet declares
SupportsShouldProcess attribute. Or please add SupportsShouldProcess attribute argument when
calling ShouldProcess.