sickle 0.4.0 → 0.5.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +0 -1
- data/lib/sickle.rb +3 -1
- data/lib/sickle/version.rb +1 -1
- data/spec/main_spec.rb +2 -2
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 00debd3cc7b7f30f2b93827acf9f2a99326d33a6
|
4
|
+
data.tar.gz: 23b4aae6aaf7d49f0b7e904c3da149d4c99fc600
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5e5bba1d613fd703374564c5429529fc709bbee9b2f0db4c08935cc8241fe7fce1ece26b1b60af28999bd4775f0535e14e67d75e7fd4bf17fa604557584974b1
|
7
|
+
data.tar.gz: 9222f26977e84917bcb8b85dff642dd201ecfb0fe0f46ae88fa023adb565929a2f23d59b6b72ef17d6c81af49e1f54713bbcc7f7ab2232f1fbc2f8f0264f77ab
|
data/.travis.yml
CHANGED
data/lib/sickle.rb
CHANGED
@@ -146,7 +146,7 @@ module Sickle
|
|
146
146
|
r == :req ? p.upcase : "[#{p.upcase}]"
|
147
147
|
end
|
148
148
|
|
149
|
-
["#{name} #{params.join(" ")}", command]
|
149
|
+
["#{name.gsub("_", "-")} #{params.join(" ")}", command]
|
150
150
|
end
|
151
151
|
|
152
152
|
def __display_help
|
@@ -230,6 +230,8 @@ module Sickle
|
|
230
230
|
# puts "ARGV: #{argv.inspect}"
|
231
231
|
|
232
232
|
if command_name = argv.shift
|
233
|
+
command_name = command_name.gsub("-", "_")
|
234
|
+
|
233
235
|
if command = __commands[command_name]
|
234
236
|
all = __global_options.values + command.options.values
|
235
237
|
|
data/lib/sickle/version.rb
CHANGED
data/spec/main_spec.rb
CHANGED
@@ -67,8 +67,8 @@ describe Sickle do
|
|
67
67
|
end
|
68
68
|
|
69
69
|
it "option with nil default" do
|
70
|
-
App.run(%w(
|
71
|
-
App.run(%w(
|
70
|
+
App.run(%w(test-option)).must_equal ["test_option", nil]
|
71
|
+
App.run(%w(test-option --null foo)).must_equal ["test_option", "foo"]
|
72
72
|
end
|
73
73
|
end
|
74
74
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sickle
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.5.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tymon Tobolski
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2013-07-
|
11
|
+
date: 2013-07-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|