(dsc): `PSResourceList` manifest migration for deprecated `whatIf` to `set.whatIfArg`
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 68/100
Research direction
Locate psresourcelist.dsc.resource.json, the Repository manifest, and the README. Compare the existing set and what-if commands with the DSC 3.2.0 whatIfArg schema, then validate the -File invocation with stdin input in pwsh. Done means both manifests use the supported schema and exit handling, and the README states the minimum DSC version.
Written by the indexing model from the issue text.
Description
Summary of the new feature / enhancement
psresourcelist.dsc.resource.json implements what-if through the top-level whatIf manifest operation. DSC deprecated that operation in 3.2.0 in favour of set.whatIfArg, where the engine appends an argument to the normal set command instead of running a separate command. Staying on whatIf means a deprecation warning today and a break when the property is removed.
Current manifest:
"whatIf": {
"executable": "pwsh",
"args": [ "-NoLogo", "-NonInteractive", "-NoProfile", "-ExecutionPolicy", "Bypass", "-Command",
"$Input | ./psresourceget.ps1 -resourcetype 'psresourcelist' -operation set -WhatIf; exit $LASTEXITCODE" ],
"input": "stdin",
"return": "state"
}
Proposed technical implementation details (optional)
- Replace the
whatIfblock with"whatIfArg": "-WhatIf"insideset. whatIfArgis appended after the existingargs, which does not work with-Command "...". Switchsetto-File ./psresourceget.ps1 -ResourceType psresourcelist -Operation setso the appended-WhatIfbinds to the script's[switch]$WhatIf. Verified locally thatpwsh -Filewith stdin input works for this script.- Bump
$schemaon both manifests to a version that includeswhatIfArgand set the minimum supported DSC version to 3.2.0 in the README. - While in the manifests, the
Repositorymanifest's-Commandinvocations should also gain; exit $LASTEXITCODEor move to-File
- Dominant language
- C#
- Stars
- 576
- Forks
- 114
- Avg merge
- 1d 2h
- Merged PRs (30d)
- 7
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from PowerShell/PSResourceGet
-
Create parent directories only after the containment check in InstallHelper.TryExtractToDirectory Open
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
PowerShell/PSResourceGet#2056 ·
-
feature_request
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
PowerShell/PSResourceGet#2013 · 3 comments ·
-
Needs-Triage
Difficulty 3/5 1-2 days Newbie friendliness 68/100
PowerShell/PSResourceGet#2055 ·
-
Needs-Triage
Difficulty 3/5 1-2 days Newbie friendliness 72/100
PowerShell/PSResourceGet#2054 ·
-
(dsc): Export ignores `--input` filter for `Repository` and `PSResourceList` on DSC 3.3.* or above OpenNeeds-Triage
Difficulty 3/5 1-2 days Newbie friendliness 72/100
PowerShell/PSResourceGet#2053 ·
All issues in PowerShell/PSResourceGet
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
-
:watch: Not Triaged 11.0 fundamentals/subsvc
Difficulty 2/5 1-3 hours Newbie friendliness 92/100
dotnet/AspNetCore.Docs#37699 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
SubtitleEdit/subtitleedit#15108 · 1 comment ·
-
area/docs-content Bug pulumi/docs
Difficulty 1/5 1-3 hours Newbie friendliness 94/100
-
agentic-workflows untriaged
Difficulty 2/5 1-3 hours Newbie friendliness 76/100