Skip to content

Terminating the app while a prompt is waiting will not restore terminal settings #2557

@lann

Description

@lann

From #2555:

Any time the spin program displays a prompt, waiting for a single keypress, it hides the cursor, e.g.

Are you sure you want to continue? [Y/n]

If I press ⌃C instead of pressing y or n, then the program aborts, but the cursor remains invisible (I'm using iTerm2.app on macOS).

I believe this could be fixed by hooking SIGINT (as we do for spin up via the ctrlc crate) and calling https://docs.rs/console/0.15.7/console/struct.Term.html#method.show_cursor (via dialoguer::console).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status

    Investigating / Open For Comment

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions