Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Add command to PSReadLine history before cancellation#1841

Merged
andyleejordan merged 1 commit into
masterPowerShell/PowerShellEditorServices:masterfrom
andschwa/add-to-historyPowerShell/PowerShellEditorServices:andschwa/add-to-historyCopy head branch name to clipboard
Jun 24, 2022
Merged

Add command to PSReadLine history before cancellation#1841
andyleejordan merged 1 commit into
masterPowerShell/PowerShellEditorServices:masterfrom
andschwa/add-to-historyPowerShell/PowerShellEditorServices:andschwa/add-to-historyCopy head branch name to clipboard

Conversation

@andyleejordan

@andyleejordan andyleejordan commented Jun 23, 2022

Copy link
Copy Markdown
Member

Otherwise PSReadLine thinks it's supposed to re-insert it in the buffer after execution.

This is an extension of #1823 which fixes PowerShell/vscode-powershell#3683, but fixes PowerShell/vscode-powershell#4041 too.

Otherwise PSReadLine thinks it's supposed to re-insert it in the buffer
after execution.
@andyleejordan andyleejordan requested a review from a team June 23, 2022 21:10
@andyleejordan andyleejordan requested a review from daxian-dbw June 23, 2022 21:12
@andyleejordan

Copy link
Copy Markdown
Member Author

TODO: Somehow add a regression test!

@andyleejordan

Copy link
Copy Markdown
Member Author

@SeeminglyScience test thoroughly please! No rush, we can get this in tomorrow and cut a new preview.

@SeeminglyScience

Copy link
Copy Markdown
Collaborator

Testing looks good!

Only one thing to note, if anyone has a custom PSRL AddToHistoryHandler it's probably going to deadlock since we're on a different thread. This isn't really new and it's what happened before Rob's rewrite, so I think that's fine, just something to keep in mind.

@SeeminglyScience SeeminglyScience left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

LGTM!

@andyleejordan andyleejordan merged commit 854665f into master Jun 24, 2022
@andyleejordan andyleejordan deleted the andschwa/add-to-history branch June 24, 2022 18:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

No open projects
Status: Done

2 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.