Title: DontShow should not hide common parameters · Issue #18472 · PowerShell/PowerShell · GitHub
Open Graph Title: DontShow should not hide common parameters · Issue #18472 · PowerShell/PowerShell
X Title: DontShow should not hide common parameters · Issue #18472 · PowerShell/PowerShell
Description: Summary of the new feature / enhancement The DontShow attribute parameter that the Parameter attribute has allows a function/script author to hide parameters like this: function Verb-Noun { Param ( [Parameter()] [string] $Param1, [Parame...
Open Graph Description: Summary of the new feature / enhancement The DontShow attribute parameter that the Parameter attribute has allows a function/script author to hide parameters like this: function Verb-Noun { Param (...
X Description: Summary of the new feature / enhancement The DontShow attribute parameter that the Parameter attribute has allows a function/script author to hide parameters like this: function Verb-Noun { Param (...
Opengraph URL: https://github.com/PowerShell/PowerShell/issues/18472
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"DontShow should not hide common parameters","articleBody":"### Summary of the new feature / enhancement\n\nThe DontShow attribute parameter that the Parameter attribute has allows a function/script author to hide parameters like this:\r\n\r\n```\r\nfunction Verb-Noun\r\n{\r\n Param\r\n (\r\n [Parameter()]\r\n [string]\r\n $Param1,\r\n\r\n [Parameter(DontShow)]\r\n [string]\r\n $Param2\r\n )\r\n}\r\n#Tab completion does not show Param2\r\nVerb-Noun -\u003cTab>\r\n```\r\n\r\nThis has the side effect of also hiding the common parameters. \r\nIt seems to have been an intentional design choice, see this: https://github.com/PowerShell/PowerShell/blob/master/src/System.Management.Automation/engine/CommandCompletion/CompletionCompleters.cs#L768 but I think that should be changed because it makes it impractical to use `DontShow` to hide old deprecated parameters like `ConvertTo-Csv` does with the `NoTypeInformation` parameter because then the user won't see important common parameters like `ErrorAction`.\n\n### Proposed technical implementation details (optional)\n\nInstead of automatically hiding common parameters when `DontShow` has been specified, add a `HideCommonParameters` parameter to the `CmdletBinding` attribute.","author":{"url":"https://github.com/MartinGC94","@type":"Person","name":"MartinGC94"},"datePublished":"2022-11-05T15:09:29Z","url":"https://github.com/PowerShell/PowerShell/issues/18472"}
| 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:ea6d3bf5-fbd1-402c-959c-e38c1af44a6c |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | D8E8:2543CD:134FE0:1B2E83:6AFD6DBF |
| html-safe-nonce | 9be98c034f64056cf11d619054854bd1480b69d523a0fa5be6762c3256248c2e |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEOEU4OjI1NDNDRDoxMzRGRTA6MUIyRTgzOjZBRkQ2REJGIiwidmlzaXRvcl9pZCI6IjQ2NzU3NDc3NzU2OTk2MzQ1NSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 37fa65512932de9cb966c7c33879a34cb32d93e9ff64290839c428b7702da453 |
| hovercard-subject-tag | issue:1437065119 |
| 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/18472/issue_layout |
| twitter:image | https://opengraph.githubassets.com/f5b68bc670a653f2c283f1ce53d405e823c2bf2747b123e9a69bc14f1a7bd2ed/PowerShell/PowerShell/issues/18472 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/f5b68bc670a653f2c283f1ce53d405e823c2bf2747b123e9a69bc14f1a7bd2ed/PowerShell/PowerShell/issues/18472 |
| og:image:alt | Summary of the new feature / enhancement The DontShow attribute parameter that the Parameter attribute has allows a function/script author to hide parameters like this: function Verb-Noun { Param (... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | MartinGC94 |
| hostname | github.com |
| expected-hostname | github.com |
| None | 9985ca2e21b59673104d4d830d4afeb946c67f248f273ab2e824c31c8db46e4a |
| 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 | 0db9e8d463c3f4540570e6ad3c501a06db9dc02a |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width