Skip to content

Broken history recall layout after console resize with multiline prompt #633

Closed

Description

I use multiline prompt, and everything works fine:

image

Except when I resize my console window then the layout of the history (Up/Down arrow) gets broken after resize:

image

When advance to new command (via Enter) it gets recovered to "valid" state. It looks like readline is recovering the prompt using the "spaces" from the old window size, rather than new lines.

Here's a profile.ps1 prompt setting that can be used to replicate the issue:

function Prompt {
    Write-Host $($ExecutionContext.SessionState.Path.CurrentLocation) -NoNewline
    return "`n" + '>' * ($nestedPromptLevel + 1) + ' '
}

Activity

  1. lzybkr commented on Feb 14, 2018

    @lzybkr
    Contributor

    This should be fixed in 2.0.0-beta1, feel free to reopen with additional details if you update and can still repro.

  2. nanoant commented on Feb 15, 2018

    @nanoant
    Author

    I confirm this is fixed in 2.0.0-beta1. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions