Class: CZDS::CLI::Main
- Inherits:
-
Thor
- Object
- Thor
- CZDS::CLI::Main
- Defined in:
- lib/czds/cli/main.rb
Instance Attribute Summary collapse
-
#tld ⇒ Object
readonly
Returns the value of attribute tld.
Instance Method Summary collapse
Instance Attribute Details
#tld ⇒ Object (readonly)
Returns the value of attribute tld.
7 8 9 |
# File 'lib/czds/cli/main.rb', line 7 def tld @tld end |
Instance Method Details
#download ⇒ Object
17 18 19 20 21 22 23 24 25 |
# File 'lib/czds/cli/main.rb', line 17 def download config_file = load_config([:config_file]) configure_client(, config_file) tld = [:tld] || config_file['tld'] || CZDS::Configuration::DEFAULTS[:tld] zone_file = CZDS::ZoneFile.new(tld) zone_file.download end |
#status ⇒ Object
34 35 36 37 38 39 40 41 42 |
# File 'lib/czds/cli/main.rb', line 34 def status config_file = load_config([:config_file]) configure_client(, config_file) tld = [:tld] || config_file['tld'] || CZDS::Configuration::DEFAULTS[:tld] zone_file = CZDS::ZoneFile.new(tld) puts zone_file.status.to_h end |