1

I want to create a CLI that takes input commands like bash, but it's displaying content on the rest of the terminal so it must not roll all the lines up when enter is pressed. It should just erase the command line instead.

I'm trying JLine3. The enterRawMode stops new lines but also stops command buffering, editing, etc.

Tried LineReaderon top of "raw mode" but it brings new lines again.

Tried playing with stty flags but can't find one to stop new lines specifically.

Victor Basso
  • 5,556
  • 5
  • 42
  • 60

1 Answers1

-1

I haven't used JLine, but you could also check out Lanterna. It gives you a lot of control over the terminal. You might have luck with either its Terminal or Screen APIs.

Rich Dougherty
  • 3,231
  • 21
  • 24