Class: Enom::Commands::DescribeDomain
- Inherits:
-
Object
- Object
- Enom::Commands::DescribeDomain
- Defined in:
- lib/enom/commands/describe_domain.rb
Instance Method Summary collapse
Instance Method Details
#execute(args, options = {}) ⇒ Object
4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 |
# File 'lib/enom/commands/describe_domain.rb', line 4 def execute(args, ={}) name = args.shift domain = Domain.find(name) puts domain.name.upcase puts "Expires: #{domain.expiration_date.strftime("%B %d, %Y")}" puts "Name Servers:" domain.nameservers.each do |ns| puts "\s\s#{ns}" end puts "Contact Info:" domain.all_contact_info.each do |k,v| puts "\s\s#{k}:" v.each do |kk,vv| puts "\s\s\s\s#{kk.gsub(k, '')}: #{vv}" end end end |