Title: Powershell does not expand '~' for external programs · Issue #20031 · PowerShell/PowerShell · GitHub
Open Graph Title: Powershell does not expand '~' for external programs · Issue #20031 · PowerShell/PowerShell
X Title: Powershell does not expand '~' for external programs · Issue #20031 · PowerShell/PowerShell
Description: Prerequisites Write a descriptive title. Make sure you are able to repro it on the latest released version Search the existing issues. Refer to the FAQ. Refer to Differences between Windows PowerShell 5.1 and PowerShell. Steps to reprodu...
Open Graph Description: Prerequisites Write a descriptive title. Make sure you are able to repro it on the latest released version Search the existing issues. Refer to the FAQ. Refer to Differences between Windows PowerSh...
X Description: Prerequisites Write a descriptive title. Make sure you are able to repro it on the latest released version Search the existing issues. Refer to the FAQ. Refer to Differences between Windows PowerSh...
Opengraph URL: https://github.com/PowerShell/PowerShell/issues/20031
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Powershell does not expand '~' for external programs","articleBody":"### Prerequisites\n\n- [X] Write a descriptive title.\n- [X] Make sure you are able to repro it on the [latest released version](https://github.com/PowerShell/PowerShell/releases)\n- [X] Search the existing issues.\n- [X] Refer to the [FAQ](https://github.com/PowerShell/PowerShell/blob/master/docs/FAQ.md).\n- [X] Refer to [Differences between Windows PowerShell 5.1 and PowerShell](https://learn.microsoft.com/powershell/scripting/whats-new/differences-from-windows-powershell).\n\n### Steps to reproduce\n\n```pwsh\r\nPS: ~ \u003e pwsh --version\r\nPowerShell 7.3.6\r\nPS: ~ \u003e cd .config/nvim\r\nPS: .config/nvim \u003e nvim ~/.bashrc # or code ~/.bashrc\r\n```\r\n- The last command opens an empty `.bashrc` file in current directory in neovim/vscode\n\n### Expected behavior\n\n```console\n`~` should be expanded to `$HOME`\n```\n\n\n### Actual behavior\n\n```console\npwsh does not expand `~` for external command\n```\n\n\n### Error details\n\n_No response_\n\n### Environment data\n\n```powershell\nName Value\r\n---- -----\r\nPSVersion 7.3.6\r\nPSEdition Core\r\nGitCommitId 7.3.6\r\nOS Microsoft Windows 10.0.19045\r\nPlatform Win32NT\r\nPSCompatibleVersions {1.0, 2.0, 3.0, 4.0…}\r\nPSRemotingProtocolVersion 2.3\r\nSerializationVersion 1.1.0.1\r\nWSManStackVersion 3.0\n```\n\n\n### Visuals\n\n_No response_","author":{"url":"https://github.com/xudyang1","@type":"Person","name":"xudyang1"},"datePublished":"2023-07-27T03:16:45.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":9},"url":"https://github.com/20031/PowerShell/issues/20031"}
| 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:d595a483-be1d-869c-4eec-470200cc027e |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 8C48:3949F8:2ECD44:40115A:6A5521E6 |
| html-safe-nonce | 9c373715e1ad53159c69ec8876ddd1add901168c8e23277ed209b43fbe80283d |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4QzQ4OjM5NDlGODoyRUNENDQ6NDAxMTVBOjZBNTUyMUU2IiwidmlzaXRvcl9pZCI6IjIwMTU1NDY0MTE5NzkxODY2NjIiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | a20a19a73c5ab61d69e3bc67e5a81d1117c610a38e607ab594f7c26df8753807 |
| hovercard-subject-tag | issue:1823537871 |
| 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/20031/issue_layout |
| twitter:image | https://opengraph.githubassets.com/599623c1ab00efc4f289a85389f9e1b2071d00a8d6e8016cbe5583acc695024b/PowerShell/PowerShell/issues/20031 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/599623c1ab00efc4f289a85389f9e1b2071d00a8d6e8016cbe5583acc695024b/PowerShell/PowerShell/issues/20031 |
| og:image:alt | Prerequisites Write a descriptive title. Make sure you are able to repro it on the latest released version Search the existing issues. Refer to the FAQ. Refer to Differences between Windows PowerSh... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | xudyang1 |
| hostname | github.com |
| expected-hostname | github.com |
| None | 682d273eacb2ac51680c6eb9c0b270f029f7ce74c32090f319083c34497e28a5 |
| 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 | 358dd24ad7465d20e3fae729b5b169d35b0dd7f8 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width