gem-wrappers 1.2.6.1 → 1.2.7

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 28326bf1c980477086ebf0a7b41c7a6895c75dd2
4
- data.tar.gz: aa27e8d17c6f6e42f14ed17115263caf8c53411a
3
+ data.tar.gz: e3c4b6e90e5eb8b635169e54b0c976962c082222
4
+ metadata.gz: 38d025a4910fed667ee8de884032a87729e549e0
5
5
  SHA512:
6
- metadata.gz: 1b26877439714640fa0638b668f32ab6509aebc9e50dd02547cf8a8a68da7e707dd2b768aa33e0816ce513ec76fa29a497a4ce241a28b3662f4b01c7e0eda06b
7
- data.tar.gz: 85f9202f66ba8ef0c70f0e5aa3ba8915357d0d40ec33521c449244e9a41ecb006f25e8d5582d7d7ac603f8e4175bf651b1fae8ea570fe8b31c1a8c5aa1cfe32c
6
+ data.tar.gz: 13d86554a5436703e8215f875811db78ecbab2b200cb01272845acc227ac850ff0e87029dd8a8974f0fd3609c6e17cf5c9c03e6fac22b5f582855c2545bc4bb8
7
+ metadata.gz: 3413b198ab7c93a41c7b4a1a5f27100d30dfb50fe54a918b927cdcbffe907841bbc99eff6e10267f9ecc1ca8b64912d849523450811d3fe6acb4a5d35d661e6a
@@ -28,12 +28,13 @@ DOC
28
28
  end
29
29
 
30
30
  def execute
31
- subcommand = get_one_optional_argument || ''
31
+ args = options[:args] || []
32
+ subcommand = args.shift || ''
32
33
  case subcommand
33
- when ''
34
- execute_show
34
+ when '', 'show'
35
+ execute_show(args)
35
36
  when 'regenerate'
36
- execute_regenerate
37
+ execute_regenerate(args)
37
38
  when FileExist
38
39
  execute_regenerate([File.expand_path(subcommand)])
39
40
  else
@@ -41,7 +42,8 @@ DOC
41
42
  end
42
43
  end
43
44
 
44
- def execute_show(list = executables)
45
+ def execute_show(list = [])
46
+ list = executables if list.empty?
45
47
  $stdout.puts description
46
48
  $stdout.puts " Wrappers path: #{gem_wrappers.wrappers_path}"
47
49
  $stdout.puts "Environment file: #{gem_wrappers.environment_file}"
@@ -54,7 +56,8 @@ DOC
54
56
  false
55
57
  end
56
58
 
57
- def execute_regenerate(list = executables)
59
+ def execute_regenerate(list = [])
60
+ list = executables if list.empty?
58
61
  execute_show(list) if ENV['GEM_WRAPPERS_DEBUG']
59
62
  gem_wrappers.install(list)
60
63
  end
@@ -1,3 +1,3 @@
1
1
  module GemWrappers
2
- VERSION = "1.2.6.1"
2
+ VERSION = "1.2.7"
3
3
  end
@@ -36,7 +36,7 @@ describe WrappersCommand do
36
36
  end
37
37
 
38
38
  it "does show" do
39
- subject.options[:args] = []
39
+ subject.options[:args] = ["show", "rake"]
40
40
  subject.execute
41
41
 
42
42
  $stderr.string.must_equal("")
@@ -44,7 +44,7 @@ describe WrappersCommand do
44
44
  #{subject.description.strip}
45
45
  Wrappers path: /path/to/wrappers
46
46
  Environment file: /path/to/environment
47
- Executables: rake, bundle, bundler
47
+ Executables: rake
48
48
  EXPECTED
49
49
  end
50
50
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gem-wrappers
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.6.1
4
+ version: 1.2.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michal Papis