Module: Doing::Prompt
- Extended by:
- Color
- Defined in:
- lib/doing/prompt.rb
Overview
Terminal Prompt methods
Constant Summary
Constants included from Color
Color::ATTRIBUTES, Color::ATTRIBUTE_NAMES, Color::COLORED_REGEXP
Class Attribute Summary collapse
Class Method Summary collapse
-
.choose_from(options, prompt: 'Make a selection: ', multiple: false, sorted: true, fzf_args: []) ⇒ String
Generate a menu of options and allow user selection.
-
.choose_from_items(items, **opt) ⇒ Object
Create an interactive menu to select from a set of Items.
- .fzf ⇒ Object
- .install_fzf ⇒ Object
-
.yn(question, default_response: false) ⇒ Bool
Ask a yes or no question in the terminal.
Methods included from Color
attributes, coloring?, support?, uncolor
Class Attribute Details
.default_answer ⇒ Object
.force_answer ⇒ Object
Class Method Details
.choose_from(options, prompt: 'Make a selection: ', multiple: false, sorted: true, fzf_args: []) ⇒ String
Generate a menu of options and allow user selection
.choose_from_items(items, **opt) ⇒ Object
Create an interactive menu to select from a set of Items
.fzf ⇒ Object
.install_fzf ⇒ Object
.yn(question, default_response: false) ⇒ Bool
Ask a yes or no question in the terminal