reverse 0.0.5 → 0.0.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/reverse.rb +8 -2
- data/lib/reverse/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b59dba1c0459be8b0514cbaf42762053d0eb9130
|
4
|
+
data.tar.gz: 6bcf2a74eecddce4c74ef816dfe99d2aa7e8f26f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 17f51fb01a1bfd49bde03921aa6d6d0ee3ae5e30ac2db426f279f23427214c7e74916a1178b130be3fa95f6e03420104b1f598fd657ffe2ecfe4d46e23898eec
|
7
|
+
data.tar.gz: f9596718298bb7eedded296e76ead8ce874ae00fe0c1548cbcd4181ff97dbae17b75859e531ae859893da3a1b84635cd56172bd6987ec6852eab7a5b26f337db
|
data/lib/reverse.rb
CHANGED
@@ -16,6 +16,7 @@ class Reverse
|
|
16
16
|
|
17
17
|
def exec(argv)
|
18
18
|
opt = OptionParser.new
|
19
|
+
opt.on('--verbose', 'Verbose Mode (IP Address with reverse DNS)') {|v| @options[:verbose] = v }
|
19
20
|
opt.on('--no-color', 'No Color Mode') {|v| @options[:color] = v }
|
20
21
|
opt.parse!(argv)
|
21
22
|
|
@@ -42,10 +43,15 @@ class Reverse
|
|
42
43
|
name = get_name(addr)
|
43
44
|
@list[addr] = name
|
44
45
|
end
|
46
|
+
if @options[:verbose]
|
47
|
+
str = "#{addr},#{name}"
|
48
|
+
else
|
49
|
+
str = name
|
50
|
+
end
|
45
51
|
if @options[:color]
|
46
|
-
color.green +
|
52
|
+
color.green + str + color.clear
|
47
53
|
else
|
48
|
-
|
54
|
+
str
|
49
55
|
end
|
50
56
|
end
|
51
57
|
end
|
data/lib/reverse/version.rb
CHANGED