Title: CLI: when installed as a .NET global tool (dotnet tool), argument parsing is broken · Issue #11747 · PowerShell/PowerShell · GitHub
Open Graph Title: CLI: when installed as a .NET global tool (dotnet tool), argument parsing is broken · Issue #11747 · PowerShell/PowerShell
X Title: CLI: when installed as a .NET global tool (dotnet tool), argument parsing is broken · Issue #11747 · PowerShell/PowerShell
Description: Note: This problem was discovered by @gerardog, and this issue is meant to supersede #11569 It only affects PowerShell when installed as a .NET global tool: dotnet tool install --global PowerShell Note: You need a .NET Core SDK 3.1 insta...
Open Graph Description: Note: This problem was discovered by @gerardog, and this issue is meant to supersede #11569 It only affects PowerShell when installed as a .NET global tool: dotnet tool install --global PowerShell ...
X Description: Note: This problem was discovered by @gerardog, and this issue is meant to supersede #11569 It only affects PowerShell when installed as a .NET global tool: dotnet tool install --global PowerShell ...
Opengraph URL: https://github.com/PowerShell/PowerShell/issues/11747
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"CLI: when installed as a .NET global tool (dotnet tool), argument parsing is broken","articleBody":"Note:\r\n\r\n* This problem was discovered by @gerardog, and this issue is meant to supersede #11569\r\n\r\n* It only affects PowerShell _when installed as a .NET global tool_:\r\n * `dotnet tool install --global PowerShell`\r\n * Note: You need a .NET Core SDK 3.1 installation first.\r\n\r\n# Steps to reproduce\r\n\r\n```powershell\r\n# NOTE: \r\n# * Problem shows if `pwsh` was installed via `dotnet tool --global`\r\n# * Run from *cmd.exe* or *bash*\r\npwsh -noprofile -c \"write-output 1 \\\"2 3\\\"\"\r\n```\r\n\r\n# Expected behavior\r\n\r\n```none\r\n1\r\n2 3\r\n```\r\n\r\nThat is, the escaped embedded double quotes (`\\\"`) should be honored, resulting in two outputs, `1`, and `'2 3'`.\r\n\r\nThis is indeed what happens with a regularly installed version.\r\n\r\n# Actual behavior\r\n\r\n```none\r\n1\r\n2\r\n3\r\n```\r\n\r\nThis output suggests that the embedded escaped double quotes (`\\\"`) were unexpectedly _eaten_.\r\n\r\n# Environment data\r\n\r\n```none\r\nPowerShell Core 7.0 # as a global .NET tool, all platforms\r\n```\r\n","author":{"url":"https://github.com/mklement0","@type":"Person","name":"mklement0"},"datePublished":"2020-01-31T20:59:29.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":10},"url":"https://github.com/11747/PowerShell/issues/11747"}
| 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:1aae8810-5844-1f63-2f9e-7f4225071e54 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | A84C:2D16FA:69A7A6A:953AD3E:6A575F19 |
| html-safe-nonce | 6e2f71c39abe0d0dfabd33c40bc5bb581150e4557e960de4a38f9a5ef14c2c8c |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBODRDOjJEMTZGQTo2OUE3QTZBOjk1M0FEM0U6NkE1NzVGMTkiLCJ2aXNpdG9yX2lkIjoiMjUxMTUxMzE5Njc5MDY1ODgxIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 286a6a1fde21900de3668b69ee107b646ef5d63faa9c77e2de2fd6cca7601301 |
| hovercard-subject-tag | issue:558369726 |
| 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/11747/issue_layout |
| twitter:image | https://opengraph.githubassets.com/a6881705355f92e4c0f579d550192ec01311b7380a4a888fed3fd80aaed8448a/PowerShell/PowerShell/issues/11747 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/a6881705355f92e4c0f579d550192ec01311b7380a4a888fed3fd80aaed8448a/PowerShell/PowerShell/issues/11747 |
| og:image:alt | Note: This problem was discovered by @gerardog, and this issue is meant to supersede #11569 It only affects PowerShell when installed as a .NET global tool: dotnet tool install --global PowerShell ... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | mklement0 |
| hostname | github.com |
| expected-hostname | github.com |
| None | 4e7a7296a3830877cf21a6ad2a972c9e618a48915e03966cf0c53eb08e5aad98 |
| 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 | 87685a1c739dbf97e95760413799bb0221799457 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width