gman 7.0.6 → 8.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 +4 -4
- data/bin/gman +10 -15
- data/bin/gman_filter +1 -1
- data/config/domains.txt +21 -408
- data/config/vendor/dotgovs.csv +237 -119
- data/docs/README.md +3 -1
- data/lib/gman/domain_list.rb +1 -1
- data/lib/gman/identifier.rb +9 -6
- data/lib/gman/importer.rb +1 -1
- data/lib/gman/locality.rb +1 -1
- data/lib/gman/version.rb +1 -1
- data/lib/gman.rb +8 -6
- metadata +8 -221
- data/.github/CODEOWNERS +0 -3
- data/.github/ISSUE_TEMPLATE/bug_report.md +0 -28
- data/.github/ISSUE_TEMPLATE/feature_request.md +0 -21
- data/.github/config.yml +0 -23
- data/.github/dependabot.yml +0 -10
- data/.github/funding.yml +0 -1
- data/.github/no-response.yml +0 -15
- data/.github/release-drafter.yml +0 -4
- data/.github/settings.yml +0 -33
- data/.github/stale.yml +0 -29
- data/.github/workflows/ci.yml +0 -23
- data/.github/workflows/clean.yml +0 -31
- data/.github/workflows/codeql-analysis.yml +0 -70
- data/.github/workflows/validate.yml +0 -30
- data/.github/workflows/vendor.yml +0 -29
- data/.gitignore +0 -6
- data/.rspec +0 -2
- data/.rubocop.yml +0 -29
- data/.rubocop_todo.yml +0 -84
- data/Gemfile +0 -5
- data/docs/CODE_OF_CONDUCT.md +0 -46
- data/docs/CONTRIBUTING.md +0 -92
- data/docs/SECURITY.md +0 -3
- data/docs/_config.yml +0 -2
- data/gman.gemspec +0 -45
- data/script/add +0 -19
- data/script/alphabetize +0 -14
- data/script/bootstrap +0 -5
- data/script/cibuild +0 -8
- data/script/console +0 -3
- data/script/dedupe +0 -22
- data/script/profile +0 -21
- data/script/prune +0 -22
- data/script/reconcile-us +0 -72
- data/script/release +0 -38
- data/script/validate-domains +0 -34
- data/script/vendor +0 -13
- data/script/vendor-federal-de +0 -14
- data/script/vendor-gov-list +0 -8
- data/script/vendor-public-suffix +0 -28
- data/script/vendor-swot +0 -43
- data/script/vendor-us +0 -42
- data/spec/fixtures/domains.txt +0 -4
- data/spec/fixtures/obama.txt +0 -5
- data/spec/gman/bin_spec.rb +0 -101
- data/spec/gman/country_code_spec.rb +0 -39
- data/spec/gman/domain_list_spec.rb +0 -110
- data/spec/gman/domains_spec.rb +0 -25
- data/spec/gman/identifier_spec.rb +0 -218
- data/spec/gman/importer_spec.rb +0 -236
- data/spec/gman/locality_spec.rb +0 -24
- data/spec/gman_spec.rb +0 -74
- data/spec/spec_helper.rb +0 -31
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 05dbe9c50c24586c2c071eccee35d04c016224fc909aea2699e09701bf0ac56b
|
|
4
|
+
data.tar.gz: f6aab93cdcec8b9c6330dfaead40263272a2cc48a075ec6549d2378c6f13c12b
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: ce3099efeaef338677d10bcfa222c7be2d10405682c9bcd0dbc33d887e6e0050eecf31bbdac2a5b703431e1516534a18f2247cf921d42931e6c12ace08171f57
|
|
7
|
+
data.tar.gz: dfe56fb1e9a5c73710fddc489c6715cd8db0835b5725bc9814c497845d98cef52ed45b9af37464fd679fa7cc1493c7e057656e5b4b3ae8497d9734f439775277
|
data/bin/gman
CHANGED
|
@@ -15,23 +15,18 @@ class IsoCountryCodes
|
|
|
15
15
|
end
|
|
16
16
|
|
|
17
17
|
domain = ARGV[0]
|
|
18
|
+
COLOR = ARGV.last != '--no-color' && ENV.fetch('NO_COLOR', '').empty?
|
|
18
19
|
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
self
|
|
23
|
-
end
|
|
20
|
+
def red(string)
|
|
21
|
+
COLOR ? "\e[31m#{string}\e[0m" : string
|
|
22
|
+
end
|
|
24
23
|
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
end
|
|
28
|
-
end
|
|
29
|
-
else
|
|
30
|
-
require 'colored'
|
|
24
|
+
def green(string)
|
|
25
|
+
COLOR ? "\e[32m#{string}\e[0m" : string
|
|
31
26
|
end
|
|
32
27
|
|
|
33
28
|
if domain.to_s.empty? || domain == '--no-color'
|
|
34
|
-
puts 'USAGE: gman <domain or email address> [--no-color]'
|
|
29
|
+
puts red('USAGE: gman <domain or email address> [--no-color]')
|
|
35
30
|
exit 1
|
|
36
31
|
end
|
|
37
32
|
|
|
@@ -40,16 +35,16 @@ gman = Gman.new(domain)
|
|
|
40
35
|
puts "Domain : #{gman.domain}"
|
|
41
36
|
|
|
42
37
|
if gman.domain.nil?
|
|
43
|
-
puts "Status : #{'Invalid domain'
|
|
38
|
+
puts "Status : #{red('Invalid domain')}"
|
|
44
39
|
exit 1
|
|
45
40
|
end
|
|
46
41
|
|
|
47
42
|
unless gman.valid?
|
|
48
|
-
puts "Status : #{'Not a government domain'
|
|
43
|
+
puts "Status : #{red('Not a government domain')}"
|
|
49
44
|
exit 1
|
|
50
45
|
end
|
|
51
46
|
|
|
52
|
-
puts "Status : #{'Valid government domain'
|
|
47
|
+
puts "Status : #{green('Valid government domain')}"
|
|
53
48
|
|
|
54
49
|
%w[type country state city agency].each do |key|
|
|
55
50
|
value = gman.send(key)
|