Repository navigation
Description
Tracked by #27565 · Design: #27697
Summary
With the per-machine data store ("MachineFolder", #27697), the effective PowerShell configuration is now merged across three scopes — MachineFolder, $PSHOME (product defaults), and CurrentUser — and the precedence differs between policy settings (system wins) and preference settings (user wins). There is currently no supported way to see the resolved result. PowerShellConfig is internal, and reading the raw powershell.config.json files by hand no longer reflects what the engine actually applies.
This is a diagnostic gap for administrators: after setting machine-wide policy, they cannot easily confirm the effective execution policy, WinCompat deny list, experimental-feature state, logging config, etc., or which scope won.
Proposal
Provide a read-only cmdlet that emits the fully merged, effective configuration (as JSON), for example:
Get-PSConfiguration [-Scope <MachineFolder|AllUsers|CurrentUser>] [-Effective]-Effective(default): the merged result the engine actually uses, honoring policy-vs-preference precedence.-Scope: dump a single scope's raw contents.- Ideally annotate each setting with the scope that "won", to make troubleshooting precedence straightforward.
The cmdlet name/shape is open for design (Get-PSConfiguration, Export-PSConfiguration, Get-PSConfiguration -AsJson, …) and needs Working Group sign-off — no public configuration cmdlet exists today.
Acceptance criteria
- Emits JSON that matches the engine's actual merge (policy → system-wins, preference → user-wins).
- Works both packaged and unpackaged (unpackaged simply has no
MachineFolderscope, so results collapse to the legacy two-scope merge). - Strictly read-only; never writes a config file.
- Preferably reports the winning source scope per setting.
Related
- Design / mechanism: [Design] MachineFolder: a per-machine writable data store for MSIX-packaged PowerShell #27697
- Config relocation implementation: Place System-Wide Config in the Machine Folder for MSIX Packages #27632
- Umbrella: Tracking: MSIX packaging gaps for PowerShell 7 #27565
Activity
jshigetomi commentedon Jul 20, 2026
Meeting follow-up note (config-visibility discussion): the design discussion for this should also weigh a DSC-based approach (a "desired configuration" solution) as an alternative — or complement — to a dedicated view/export cmdlet. In other words, decide whether administrators should manage and inspect the system-wide, merged configuration through a DSC resource rather than (or in addition to) something like
Get-PSConfiguration -Effective. Capturing here so the option is evaluated during Working Group design rather than defaulting straight to a cmdlet.kilasuit commentedon Nov 14, 2026
Likely linked / potential overlap with already WG approved new Cmdlets for returning/manipulating
powershell.config.jsonfiles