Closed JustinGrote closed 1 year ago
@JustinGrote we had that but doing so ruins other tools. We reset the colors so this is a PowerShell bug.
@JanDeDobbeleer do you have an example or a previous issue I missed? Maybe what you mean by "ruins other tools"? Is it possible to emit VT codes directly to the template so I can experiment?
@JustinGrote wait, I misread the issue. We invoke a prompt reload for transient so there's no magic involved. We even set the prompt line count dynamically, so that's also covered. I seem to remember a similar bug report in the past with no solution available. So definitely something for PSReadLine to look at.
My understanding is you issue all the VT commands to clear the buffer independent of psreadline unless I"m misreading the code, so at this point: Why can't you issue an ESC[0J (clear everything after the cursor) before objects start being output again?
Or do you think this is something PSReadline should be doing if you're just invoking the prompt again as part of transient?
Or do you think this is something PSReadline should be doing if you're just invoking the prompt again as part of transient?
@JustinGrote yes, I expect PSReadLine to correctly reload the prompt. I'll do a quick test on my end to see if we could solve this as you can't add that to the prompt easily (we always print something afterwards).
This issue has been automatically locked since there has not been any recent activity (i.e. last half year) after it was closed. It helps our maintainers focus on the active issues. If you have found a problem that seems similar, please open a discussion first, complete the body with all the details necessary to reproduce, and mention this issue as reference.
Code of Conduct
What happened?
Probably should issue an ansi "clear right of cursor" or "clear all below transient prompt" prior to the command output.
Theme
What OS are you seeing the problem on?
Windows
Which shell are you using?
powershell
Log output