visionmedia-commander 2.4.4 → 2.4.6
Sign up to get free protection for your applications and to get access to all the features.
- data/History.rdoc +5 -0
- data/Todo.rdoc +4 -0
- data/commander.gemspec +2 -5
- data/lib/commander/runner.rb +1 -1
- data/lib/commander/version.rb +1 -1
- data/spec/commander_spec.rb +3 -3
- metadata +3 -11
data/History.rdoc
CHANGED
data/Todo.rdoc
CHANGED
@@ -1,4 +1,8 @@
|
|
1
1
|
|
2
|
+
* Fix issue with having command name in the args list, #args_without_command
|
3
|
+
* Add optional command to be executed when none is specified
|
4
|
+
* Add aliasing of commands / args / options
|
5
|
+
* Non-greedy matching of command name
|
2
6
|
* Change; Have VerboseFileUtils only output basename ?
|
3
7
|
* Change; refactor specs
|
4
8
|
* Release to RubyForge as well
|
data/commander.gemspec
CHANGED
@@ -2,11 +2,11 @@
|
|
2
2
|
|
3
3
|
Gem::Specification.new do |s|
|
4
4
|
s.name = %q{commander}
|
5
|
-
s.version = "2.4.
|
5
|
+
s.version = "2.4.6"
|
6
6
|
|
7
7
|
s.required_rubygems_version = Gem::Requirement.new(">= 1.2") if s.respond_to? :required_rubygems_version=
|
8
8
|
s.authors = ["TJ Holowaychuk"]
|
9
|
-
s.date = %q{2009-
|
9
|
+
s.date = %q{2009-03-03}
|
10
10
|
s.default_executable = %q{commander}
|
11
11
|
s.description = %q{The complete solution for Ruby command-line executables}
|
12
12
|
s.email = %q{tj@vision-media.ca}
|
@@ -27,13 +27,10 @@ Gem::Specification.new do |s|
|
|
27
27
|
|
28
28
|
if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
|
29
29
|
s.add_runtime_dependency(%q<highline>, [">= 1.5.0"])
|
30
|
-
s.add_development_dependency(%q<echoe>, [">= 0"])
|
31
30
|
else
|
32
31
|
s.add_dependency(%q<highline>, [">= 1.5.0"])
|
33
|
-
s.add_dependency(%q<echoe>, [">= 0"])
|
34
32
|
end
|
35
33
|
else
|
36
34
|
s.add_dependency(%q<highline>, [">= 1.5.0"])
|
37
|
-
s.add_dependency(%q<echoe>, [">= 0"])
|
38
35
|
end
|
39
36
|
end
|
data/lib/commander/runner.rb
CHANGED
data/lib/commander/version.rb
CHANGED
data/spec/commander_spec.rb
CHANGED
@@ -210,15 +210,15 @@ describe Commander do
|
|
210
210
|
it "should allow multi-word strings as command names to be called correctly" do
|
211
211
|
arguments = nil
|
212
212
|
options = nil
|
213
|
-
new_command_runner 'foo', 'bar', 'something', 'i', 'like', '--i-like', 'cookies'
|
213
|
+
new_command_runner 'foo', 'bar', 'something', 'i', 'like', '--i-like', 'cookies'
|
214
214
|
command 'foo bar something' do |c|
|
215
215
|
c.option '--i-like WHAT'
|
216
216
|
c.when_called { |args, opts| arguments, options = args, opts }
|
217
217
|
end
|
218
218
|
command_runner.command_name_from_args.should eql('foo bar something')
|
219
|
-
command_runner.args_without_command.should eql(['i', 'like', '--i-like', 'cookies'
|
219
|
+
command_runner.args_without_command.should eql(['i', 'like', '--i-like', 'cookies'])
|
220
220
|
command_runner.run!
|
221
|
-
arguments.should eql(['i', 'like'
|
221
|
+
arguments.should eql(['i', 'like'])
|
222
222
|
options.i_like.should eql('cookies')
|
223
223
|
end
|
224
224
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: visionmedia-commander
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.4.
|
4
|
+
version: 2.4.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- TJ Holowaychuk
|
@@ -9,11 +9,12 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2009-
|
12
|
+
date: 2009-03-03 00:00:00 -08:00
|
13
13
|
default_executable: commander
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: highline
|
17
|
+
type: :runtime
|
17
18
|
version_requirement:
|
18
19
|
version_requirements: !ruby/object:Gem::Requirement
|
19
20
|
requirements:
|
@@ -21,15 +22,6 @@ dependencies:
|
|
21
22
|
- !ruby/object:Gem::Version
|
22
23
|
version: 1.5.0
|
23
24
|
version:
|
24
|
-
- !ruby/object:Gem::Dependency
|
25
|
-
name: echoe
|
26
|
-
version_requirement:
|
27
|
-
version_requirements: !ruby/object:Gem::Requirement
|
28
|
-
requirements:
|
29
|
-
- - ">="
|
30
|
-
- !ruby/object:Gem::Version
|
31
|
-
version: "0"
|
32
|
-
version:
|
33
25
|
description: The complete solution for Ruby command-line executables
|
34
26
|
email: tj@vision-media.ca
|
35
27
|
executables:
|