What does HackerNews think of lanterna?

Java library for creating text-based GUIs

Language: Java

I wrote a TUI before for work, entirely of my own volition and for my own near-exclusive consumption (it was theoretically for anyone, but I'm the only person who would've had a reason to look at it - we were a fairly silo'd dev shop).

This is what made me pick TUI over a web UI:

* no web stack, period. no client/server. no js or html. this simplified the problem dramatically. also, no additional services to babysit.

* no browser - no certificates, security, auth, etc. It's just unix permissions and ssh.

* there's something comforting about the constraints of just ASCII/ANSI and curses. No bikeshedding over border widths or radii when it's just you picking among a few characters for the shape. just having less decisions to make speeds things up and helps you focus on what you actually want the UI to be able to do.

Obviously if your app is just calling APIs anyway, that might be negate some of these bullets about no additional services to babysit etc. In this case, it was running an internal infra app that directly connected to a pg db.

And what made me pick it over just having a CLI:

* discoverability - it was a complicated app and while it was all technically exposed via cli flags, having a GUI made it a lot easier to figure out what the right incantation is.

* richer communication medium that's back-and-forth instead of unidirectional. The TUI is able to fetch a list of e.g. valid IDs and let you pick them with a check-list, instead of you having to go query the db yourself and type them in.

I consider it one of my greatest victories that my boss was able to use the TUI to recover from an incident without needing to page me while I was on holiday, and he said he barely had to read the docs and felt confident he was getting it right the first time. "I did it while sipping my coffee."

I used https://github.com/mabe02/lanterna - would recommend. They even have a Swing-based emulation mode for easy development iteration running it from intelliJ.

A couple of TUI libraries for Java:

http://www.pitman.co.za/projects/charva/Screenshots.html

https://github.com/mabe02/lanterna

And, lower level, there's jCurses, which despite the name, also works on Windows:

https://github.com/kba/jcurses

I'm using Lanterna, a Java library for creating text-based terminal GUIs (https://github.com/mabe02/lanterna), and the startup is 1-2 seconds. Can't recommend it enough