Inquirer::Console
Provides Inquirer with various printing utilities.
Constants
COLUMNS = ENV["COLUMNS"]?.try(&.to_i) || 80
The amount of columns in terminal.
DONE_FORE = Colorize::ColorRGB.new(165, 214, 167)
Done plaque background color.
ERROR_FORE = Colorize::ColorRGB.new(239, 154, 154)
Error plaque background color.
PROGRESS_FORE = Colorize::ColorRGB.new(144, 202, 249)
Progress plaque background color.
Instance methods
exit(status : Int32, message : String)
Exits with status status.
If status is not zero, an error with the given
message is printed.
update(message : String)
Displays message, assuming it will change the next moment.
Works like Crystal's print, but returns the carriage
to the start of the line and clears that line before
printing.
Cuts off the message if it is too long to display on one line.
Returns nothing.
Macros
logging(before, after, given)
Logs progress with message before, executes given
and logs done with message after.
Returns whatever given returned.