Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix shell integration for PowerShell 5.1 #170516

Merged
merged 2 commits into from Jan 12, 2023

Conversation

andyleejordan
Copy link
Member

The pipeline operator cannot be used on a new line, which caused #167068.

Also sets the dubious runtime "strict mode" PowerShell feature off in the prompt function. Note that this is off by default, but can be turned on by users, leading to cryptic issues as this code expects $LastHistoryEntry.Id to just be return $Null when $LastHistoryEntry is $Null (a reasonable expectation and valid PowerShell code, just against "strict" mode's guidelines). This caused PowerShell/vscode-powershell#4343.

Image of it working again:

Screenshot 2023-01-03 at 12 23 25 PM

@Tyriar Tyriar added this to the January 2023 milestone Jan 10, 2023
Copy link
Member

@Tyriar Tyriar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @andschwa 👍

@Tyriar Tyriar merged commit 7e54126 into microsoft:main Jan 12, 2023
@andyleejordan andyleejordan deleted the andschwa/shell-integration branch January 12, 2023 17:43
@github-actions github-actions bot locked and limited conversation to collaborators Feb 26, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants