Title: Add a `-UICulture` parameter to Get-Help to view help in a chosen language · Issue #28384 · PowerShell/PowerShell · GitHub
Open Graph Title: Add a `-UICulture` parameter to Get-Help to view help in a chosen language · Issue #28384 · PowerShell/PowerShell
X Title: Add a `-UICulture` parameter to Get-Help to view help in a chosen language · Issue #28384 · PowerShell/PowerShell
Description: Summary of the new feature / enhancement As a user I want to specify the UI culture when running Get-Help, so that I can read help content in the language I choose, independently of my operating system's display language. PowerShell's up...
Open Graph Description: Summary of the new feature / enhancement As a user I want to specify the UI culture when running Get-Help, so that I can read help content in the language I choose, independently of my operating sy...
X Description: Summary of the new feature / enhancement As a user I want to specify the UI culture when running Get-Help, so that I can read help content in the language I choose, independently of my operating sy...
Opengraph URL: https://github.com/PowerShell/PowerShell/issues/28384
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Add a `-UICulture` parameter to Get-Help to view help in a chosen language","articleBody":"### Summary of the new feature / enhancement\n\nAs a user I want to specify the UI culture when running `Get-Help`, so that I can read help content in the language I choose, independently of my operating system's display language.\n\nPowerShell's updatable help is asymmetric today:\n\n- `Update-Help -UICulture \u003cculture>` and `Save-Help -UICulture \u003cculture>` can **install** help content for any culture, side by side (`$PSHOME\\\u003cculture>\\`, `\u003cmodule>\\\u003cculture>\\`).\n- `Get-Help` cannot **view** a specific culture. It always resolves content using the ambient thread UI culture (`CultureInfo.CurrentUICulture`), with the MUI fallback chain `\u003ccurrent> -> parent cultures -> '' -> en-US -> en`.\n\nSo help content a user installed in a second language is unreachable without changing the machine or session culture. Concrete pain points:\n\n1. Users on a non-English OS who prefer English help (or vice versa) have no supported switch. The only workaround is manually setting the whole thread culture (`[System.Threading.Thread]::CurrentThread.CurrentUICulture = 'en-US'`), which mutates the entire runspace, also changes the language of engine error messages, and is per-runspace.\n2. Authors and testers of localized modules or localized `about_*` topics cannot verify their content without switching their environment's culture.\n3. CI cannot exercise localized help in-process.\n\nScope note: comment-based help is single-language by design. `-UICulture` affects file-based help content: MAML XML help shipped by modules or installed via `Update-Help`, culture-specific `about_*` topics, and provider help. For a module that only ships comment-based help, the parameter has no visible effect. When the parameter is omitted, behavior is exactly as today.\n\n### Proposed technical implementation details (optional)\n\n#### Example experience\n\n```powershell\n# OS UI culture is de-DE; English help additionally installed with:\nUpdate-Help -UICulture en-US\n\nGet-Help Get-ChildItem # de-DE help (default, unchanged)\nGet-Help Get-ChildItem -UICulture en-US # en-US help, without touching the session culture\nGet-Help about_Logging -UICulture en-US # about topics resolve the same way\nGet-Help Get-ChildItem -UICulture nl-NL # nl-NL not installed -> falls back nl -> en-US -> en,\n # the same fallback chain used today\n```\n\n#### How the language is picked today\n\n```text\nGet-Help cmdlet (help/HelpCommands.cs, class GetHelpCommand)\n |\n v\nHelpRequest (help/HelpRequest.cs - carries target, category, filters...\n | but NO culture field)\n v\nHelpSystem / providers (help/HelpSystem.cs, *HelpProvider.cs)\n |\n v\nMUIFileSearcher (help/MUIFileSearcher.cs - HERE the culture is chosen:\n | reads CultureInfo.CurrentUICulture and searches\n v \u003cculture>\\, parent cultures, '', en-US\\, en\\)\n```\n\nThe language decision happens implicitly, deep inside the engine. There is no way for the caller to influence it.\n\n#### The new parameter\n\nAdded to `GetHelpCommand`, valid in all parameter sets:\n\n```csharp\n/// \u003csummary>\n/// Gets or sets the UI culture of the help content to return.\n/// When not specified, the current UI culture is used (existing behavior).\n/// \u003c/summary>\n[Parameter]\n[ValidateNotNull]\n[Alias(\"Language\")]\npublic CultureInfo UICulture { get; set; }\n```\n\n- Type `System.Globalization.CultureInfo`, matching the existing `-UICulture` parameters of `Update-Help`/`Save-Help`; `'en-US'` strings bind natively.\n- No wildcards (`Update-Help` processes a *set* of cultures for bulk downloads; a single help lookup has no meaningful wildcard semantics).\n- Allowed in remote/restricted sessions: it is a pure content lookup, like `-Name` (unlike `-Online`/`-ShowWindow`).\n- `-Language` works as an alias for discoverability.\n\n#### What changes, and where (all under src/System.Management.Automation/help/)\n\n1. **`HelpCommands.cs`** - `GetHelpCommand` gets the `-UICulture` parameter shown above and copies its value into the `HelpRequest` it already builds.\n2. **`HelpRequest.cs`** - new internal property `CultureInfo RequestedUICulture`. `null` means \"use the ambient culture\", so all existing call sites that build `HelpRequest` directly (e.g. `GetHelpCodeMethods.GetHelpUri`) are unaffected.\n3. **`MUIFileSearcher.cs`** - the static `SearchFiles`/`LocateFile` APIs gain an optional culture argument. The only change to the search itself: the fallback chain is built from the *requested* culture when one is present, otherwise from `CultureInfo.CurrentUICulture` as today. Chain order and the en-US/en fallback stay identical.\n4. **`HelpSystem.cs` + providers** - pass the request's culture down to the file searchers instead of relying on ambient culture.\n5. **`HelpRepository.cs`** - audit that cached help entries are keyed per culture, so a session mixing `Get-Help` calls in different cultures cannot serve stale or mixed-language content (regression test included).\n\nOne rule summarizes the design: **if the request carries a culture, it wins for this one lookup; otherwise nothing changes.**\n\n#### Alternatives considered\n\n- **Temporarily switching `CultureInfo.CurrentUICulture` inside the cmdlet** - smallest diff, but mutating ambient thread state from a cmdlet is unsafe with concurrent/nested pipelines.\n- **A script-level proxy function** - impossible: the culture is read deep inside SMA's help engine, unreachable from script.\n\n#### Tests\n\n`test/powershell/Modules/Microsoft.PowerShell.Utility/Get-Help.Tests.ps1`, with a fixture module shipping a second culture's `about_*` topic (and ideally a small MAML help file):\n\n- requested culture is honored for command help and about topics;\n- fallback still ends in en-US/en when the requested culture is not installed;\n- omitting the parameter behaves identically to today;\n- mixed-culture calls in one session do not cross-contaminate results.\n\n### Related issues\n\n- #26724 - user with a Chinese OS wanting English help; no supported switch exists (closed as a support question, but demonstrates the demand).\n- #6217 - help files for cultures other than en-US.\n- #28274 / #21187 - adjacent HelpSystem caching/discovery issues the implementation must respect.\n\n(A search for an existing feature request for this turned up nothing - closest are the issues above.)\n","author":{"url":"https://github.com/soroshsabz","@type":"Person","name":"soroshsabz"},"datePublished":"2026-11-10T10:40:11Z","url":"https://github.com/PowerShell/PowerShell/issues/28384"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:3684f451-5ee0-c895-f886-ece3570873c9 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 9D42:3FEEFA:6A171:92083:6AFCE835 |
| html-safe-nonce | 3ceb952ba5720181417629c0ac0c90bf4412d988e918d18b3daa4fd0660a8692 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5RDQyOjNGRUVGQTo2QTE3MTo5MjA4Mzo2QUZDRTgzNSIsInZpc2l0b3JfaWQiOiI1MzI1NjA0OTExNjE2NjgyMDM3IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 37807d0e600311a45e8c1069e29b643251da4a7154ea16a82b31377264351354 |
| hovercard-subject-tag | issue:6305163698 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/PowerShell/PowerShell/28384/issue_layout |
| twitter:image | https://opengraph.githubassets.com/04f3420ffacb2e1f1e012ba16374e4595a0ea98d85b2e8954544061f4df5d82a/PowerShell/PowerShell/issues/28384 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/04f3420ffacb2e1f1e012ba16374e4595a0ea98d85b2e8954544061f4df5d82a/PowerShell/PowerShell/issues/28384 |
| og:image:alt | Summary of the new feature / enhancement As a user I want to specify the UI culture when running Get-Help, so that I can read help content in the language I choose, independently of my operating sy... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | soroshsabz |
| hostname | github.com |
| expected-hostname | github.com |
| None | 99aede4c5f55ec5cf06666a8c9e03ebf9f85f7231223e7f1c38c16e5504835b3 |
| turbo-cache-control | no-preview |
| go-import | github.com/PowerShell/PowerShell git https://github.com/PowerShell/PowerShell.git |
| octolytics-dimension-user_id | 11524380 |
| octolytics-dimension-user_login | PowerShell |
| octolytics-dimension-repository_id | 49609581 |
| octolytics-dimension-repository_nwo | PowerShell/PowerShell |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 49609581 |
| octolytics-dimension-repository_network_root_nwo | PowerShell/PowerShell |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | ecfd63ca125ec74b42f74eeb158b3fa081c8c497 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width