Class: Wedding::CLI
- Inherits:
-
Thor
- Object
- Thor
- Wedding::CLI
- Defined in:
- lib/wedding/cli.rb
Overview
Command line interface for the wedding
Instance Method Summary collapse
Instance Method Details
#bride ⇒ Object
39 40 41 |
# File 'lib/wedding/cli.rb', line 39 def bride puts Wedding.ceremony.bride end |
#groom ⇒ Object
34 35 36 |
# File 'lib/wedding/cli.rb', line 34 def groom puts Wedding.ceremony.groom end |
#invitation ⇒ Object
11 12 13 |
# File 'lib/wedding/cli.rb', line 11 def invitation puts Wedding.ceremony.invitation end |
#location ⇒ Object
16 17 18 19 20 21 22 23 24 25 26 |
# File 'lib/wedding/cli.rb', line 16 def location puts map_location = Wedding.ceremony.location answer = yes?('Do you want to open this link in browser? (yes/no)') if (answer) begin Launchy.open(map_location) rescue StandardError => e puts "Sorry, you are probably not using a graphical terminal" end end end |
#rsvp ⇒ Object
29 30 31 |
# File 'lib/wedding/cli.rb', line 29 def rsvp puts Wedding.ceremony.rsvp end |