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

Arrow keys history also counts empty lines #4

Closed
ivanjx opened this issue May 31, 2021 · 1 comment · Fixed by #3
Closed

Arrow keys history also counts empty lines #4

ivanjx opened this issue May 31, 2021 · 1 comment · Fixed by #3

Comments

@ivanjx
Copy link
Contributor

ivanjx commented May 31, 2021

When i tried to use up arrow keys to display the first line again in this example, i need to press it 8 times so it seems like it also counts on the empty lines. Is this intended? Thanks.
image

@waf
Copy link
Owner

waf commented Jun 1, 2021

Thanks for raising this! Yeah, I wasn't sure which approach was better:

  • Trim empty lines from the history
  • Leave the user's history untouched, so it matches exactly what the user sees.

I think you're right that we should trim the empty lines; if the user needs an empty line they can always just press ctrl-c, to cancel the current line. I'll see if I can get that implemented over the next few days. Thanks!

@waf waf transferred this issue from waf/CSharpRepl Jun 1, 2021
@waf waf linked a pull request Jun 1, 2021 that will close this issue
@waf waf closed this as completed Jun 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants