choosy 0.2.2 → 0.2.3

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.
@@ -1 +1 @@
1
- 0.2.2
1
+ 0.2.3
@@ -34,8 +34,13 @@ module Choosy
34
34
  end
35
35
 
36
36
  super_result.subresults.each do |result|
37
- cmd = result.command
38
- cmd.executor.call(result.options, result.args)
37
+ executor = result.command.executor
38
+
39
+ if executor.is_a?(Proc)
40
+ executor.call(result.args, result.options)
41
+ else
42
+ executor.execute!(result.args, result.options)
43
+ end
39
44
  end
40
45
  end
41
46
 
@@ -66,8 +66,8 @@ module Choosy
66
66
  @c.alter do
67
67
  command :bar do
68
68
  integer :count, "The count"
69
- executor do |opts, args|
70
- count = opts[:count]
69
+ executor do |args, options|
70
+ count = options[:count]
71
71
  end
72
72
  end
73
73
  end
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 2
8
- - 2
9
- version: 0.2.2
8
+ - 3
9
+ version: 0.2.3
10
10
  platform: ruby
11
11
  authors:
12
12
  - Gabe McArthur