Module: StackMaster::Prompter
- Included in:
- Commands::Apply, Commands::Delete
- Defined in:
- lib/stack_master/prompter.rb
Instance Method Summary collapse
Instance Method Details
#ask?(question) ⇒ Boolean
3 4 5 6 7 8 9 10 11 12 |
# File 'lib/stack_master/prompter.rb', line 3 def ask?(question) StackMaster.stdout.print question answer = if ENV['STUB_AWS'] ENV['ANSWER'] else STDIN.getch.chomp end StackMaster.stdout.puts answer == 'y' end |