domain_expiry 0.1.1 → 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: b27cb0f8e9e9548da93a7688b2890822538bbe4f
4
- data.tar.gz: dbbb4df7659ce290a45e08a09ec5b2e72857e282
3
+ metadata.gz: 6d74446ead3ce9287bc4ae5c0944f37be58e2a81
4
+ data.tar.gz: 3220dc30b8fd33478d75bad97a67d5c14bb6b265
5
5
  SHA512:
6
- metadata.gz: 6791ec1bebcf9e20e88b1e1e5d093906d95c8ec7b1f8833e27b4abe910feb532cb226fc68b53654a2f16bd28d55486ec4510a4716745df6bc21e96192eb66e31
7
- data.tar.gz: 73d60f2833838a4fe9835c0a371279bb9c3c20bea334aac992d33620f41d1bdbe5c9df257c1bb2169d7a49b52e7c37d25ad774e56c7705c46d968529b50fc502
6
+ metadata.gz: 7b3ceef9ed6aa70f8b6b154644322ff5472d3317d80da70d22623f77198532c77ad995365193ae134be7ea11c192d2f8cc8794d7b93a3ba10aa038022dc8b445
7
+ data.tar.gz: 5e97ef03262086b685c208cb8be906d9887ffc6dd48ac916277e2599a2c6948bae6bf43cca3296558f9272ffc7487ab9d1370ab7a09954bab1c4e18d497bd45e
data/README.md CHANGED
@@ -28,24 +28,48 @@ Or install it yourself as:
28
28
 
29
29
  ## Usage
30
30
 
31
+ ### Simple Usage
31
32
  ```ruby
32
33
  require 'domain_expiry'
33
34
 
34
35
  DomainExpiry::DomainExpiry.domain_details('antiphoton.com')
36
+
37
+ Results:
38
+ {"antiphoton.com"=>{"status"=>200, "expires_on"=>"11 Oct 2020", "expires_in"=>598}}
35
39
  ```
36
40
 
41
+ ### Displaying the output
42
+
37
43
  ```ruby
38
44
  require 'domain_expiry'
39
45
 
40
46
  results = DomainExpiry::DomainExpiry.domain_details(['antiphoton.com','wolfsoftware.com'])
41
47
  DomainExpiry::DomainExpiry.display_results(results)
48
+ ```
49
+
50
+ This would give the following output
51
+
52
+ ```shell
53
+ --------------------------------------------------------------------------------
54
+ Domain | Status
55
+ --------------------------------------------------------------------------------
56
+ antiphoton.com | expires on 11 Oct 2020 (in 598 days)
57
+ wolfsoftware.com | expires on 24 Jan 2022 (in 1068 days)
58
+ --------------------------------------------------------------------------------
59
+ ```
60
+
61
+ ## Command Line Tools
62
+
63
+ There is a command line tool included with this gem.
64
+
65
+ ```shell
66
+ check-domain -d antiphoton.com
42
67
 
43
- ------------------------------------------------------------------------------------------------------------------------
44
- Domain | Status
45
- ------------------------------------------------------------------------------------------------------------------------
46
- antiphoton.com | expires on 11 Oct 2020 (in 598 days)
47
- wolfsoftware.com | expires on 24 Jan 2022 (in 1068 days)
48
- ------------------------------------------------------------------------------------------------------------------------
68
+ --------------------------------------------------------------------------------
69
+ Domain | Status
70
+ --------------------------------------------------------------------------------
71
+ antiphoton.com | expires on 11 Oct 2020 (in 598 days)
72
+ --------------------------------------------------------------------------------
49
73
  ```
50
74
 
51
75
  ## Development
data/lib/domain_expiry.rb CHANGED
@@ -62,7 +62,7 @@ module DomainExpiry
62
62
  delim = '-' * width
63
63
 
64
64
  puts(delim)
65
- printf(' %-30s | %<status>s\n', 'Domain', status: 'Status')
65
+ printf(" %-30s | %s\n", 'Domain', 'Status')
66
66
  puts(delim)
67
67
 
68
68
  results.each do |domain, details|
@@ -71,7 +71,7 @@ module DomainExpiry
71
71
  else
72
72
  format('expires on %<expires_in>s (in %<expires_on>s days)', expires_in: details['expires_on'], expires_on: details['expires_in'])
73
73
  end
74
- printf(' %-30s | %s\n', domain, status)
74
+ printf(" %-30s | %s\n", domain, status)
75
75
  end
76
76
  puts(delim)
77
77
  end
@@ -1,3 +1,3 @@
1
1
  module DomainExpiry
2
- VERSION = '0.1.1'.freeze
2
+ VERSION = '1.0.0'.freeze
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: domain_expiry
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 1.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tim Gurney aka Wolf