News for hackers. Stuff that matters.
Re:Show HN: Promptui – Rich UI elements for cli prompts in Go by igitur on Wednesday November 29, 2017 @04:12PM (#15810901)
I like this. Do similar projects exist for other languages?
Re:Show HN: Promptui – Rich UI elements for cli prompts in Go by luizbranco on Wednesday November 29, 2017 @04:21PM (#15810971)
Any language in particular? For JavaScript I'd recommend https://github.com/SBoudrias/Inquirer.js
Re:Show HN: Promptui – Rich UI elements for cli prompts in Go by fabiospampinato on Wednesday November 29, 2017 @06:01PM (#15811716)
I agree.

I've published a package that exposes a few convenience methods written using it, including a cool one for printing a table (which detects the width of the terminal window and hides extra columns automatically). Check it out https://github.com/fabiospampinato/inquirer-helpers

Re:Show HN: Promptui – Rich UI elements for cli prompts in Go by shakna on Thursday November 30, 2017 @02:37AM (#15814059)
I feel the need to mention "newt" [0][1] here.

It's the C library behind whiptail, a reimplementation of dialog, which is a cli app for making menus. Incidentally, dialog is usually what you see when you get a semi-gui install with many Linux distributions.

Being C, you can use it with just about everything.

[0] https://en.wikipedia.org/wiki/Newt_%28programming_library%29

[1] https://pagure.io/newt

Re:Show HN: Promptui – Rich UI elements for cli prompts in Go by jernfrost on Wednesday November 29, 2017 @08:10PM (#15812505)
While not quite the same, the REPL of the Julia programming language supports modes as plugins. Out of the box there is the Julia mode for writing julia code, shell mode for shell commands and help mode for getting help on functions. But I've seen lots of interesting ways of extending this.

E.g. one of the debuggers for Julia, Gallium simply adds some new modes. So you can be in stepping-through-code-mode and then at any time switch back to Julia mode and inspect variables at that point in the execution stack.

Another mode is a package mode being developed for the new Julia package manager. So when adding, removing, updating, creating etc packages you can go into package mode and get behavior relevant to working with packages.

I had the idea of creating a mode for a board game, e.g. a Settlers of Catan mode, which is focused on issuing commands relevant to that game.

Re:Show HN: Promptui – Rich UI elements for cli prompts in Go by floatboth on Thursday November 30, 2017 @05:22AM (#15814724)
Re:Show HN: Promptui – Rich UI elements for cli prompts in Go by baliex on Wednesday November 29, 2017 @05:14PM (#15811392)
I'd be interested in something like this for python
Re:Show HN: Promptui – Rich UI elements for cli prompts in Go by quodlibetor on Wednesday November 29, 2017 @08:23PM (#15812597)
prompt_toolkit is, IMO, the standard by which all of these types of libraries should be measured.

It's incredibly easy to get started with, and lets you build crazy wonderful things like pt_python and pgcli/mycli.

Re:Show HN: Promptui – Rich UI elements for cli prompts in Go by cosud on Thursday November 30, 2017 @03:03AM (#15814133)
For REPL like things prompt_toolkit is great. For anything else (menus, forms) i find it difficult to use or at least discouraging.
Re:Show HN: Promptui – Rich UI elements for cli prompts in Go by aoeusnth1 on Wednesday November 29, 2017 @07:30PM (#15812250)
Me too, I would definitely use a fancy python CLI library.
Re:Show HN: Promptui – Rich UI elements for cli prompts in Go by j_s on Thursday November 30, 2017 @02:02PM (#15818490)
Suprised to not see ncurses mentioned anywhere yet. Not sure it's an exact match but it's well supported in the same ballpark.
Re:Show HN: Promptui – Rich UI elements for cli prompts in Go by igitur on Monday December 04, 2017 @06:32AM (#15843139)
Anything like this for a .NET command line application?