todo_lint 0.2.1 → 0.2.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/todo_lint/options.rb +11 -0
- data/lib/todo_lint/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: d011bff9f0a8228d2e3d127558707114d56c85bb
|
4
|
+
data.tar.gz: 3aa5fe621ac4f6c9f501ef1886f736dc056a46b1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 604e3af044f0c5e8d676e7c8027af31d77e51910a63ffdf677d33793028209b8787c8756cab5c890be65c45cfe36ab0703237626ceb5f3a00c7fb85691ede30a
|
7
|
+
data.tar.gz: cb656f930d3538df3d261fb2abf86d63f13911216429cc275e33bd6bf11eb6e608ff673d823ec0882394297ccbc7a0453bb38c8c08db275b05b590a838b68917
|
data/lib/todo_lint/options.rb
CHANGED
@@ -16,6 +16,7 @@ module TodoLint
|
|
16
16
|
add_config_options parser
|
17
17
|
exclude_file_options parser
|
18
18
|
include_extension_options parser
|
19
|
+
report_version parser
|
19
20
|
end.parse!(args)
|
20
21
|
|
21
22
|
# Any remaining arguments are assumed to be files
|
@@ -60,6 +61,16 @@ module TodoLint
|
|
60
61
|
end
|
61
62
|
end
|
62
63
|
|
64
|
+
# Reports the current version of the gem and that's it!
|
65
|
+
# @api private
|
66
|
+
# @return [Hash]
|
67
|
+
def report_version(parser)
|
68
|
+
parser.on("-v", "--version") do
|
69
|
+
puts VERSION
|
70
|
+
exit
|
71
|
+
end
|
72
|
+
end
|
73
|
+
|
63
74
|
# Options hash for all configurations
|
64
75
|
# @return [Hash]
|
65
76
|
# @api private
|
data/lib/todo_lint/version.rb
CHANGED