guns 0.1.2 → 0.1.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. data/guns.gemspec +1 -1
  2. data/lib/guns.rb +4 -3
  3. metadata +1 -1
@@ -3,7 +3,7 @@ Gem::Specification.new do |s|
3
3
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
4
4
 
5
5
  s.name = 'guns'
6
- s.version = '0.1.2'
6
+ s.version = '0.1.3'
7
7
  s.date = '2009-10-30'
8
8
 
9
9
  s.description = "Guns - It's got two pipes; got tickets to the show?"
@@ -49,9 +49,10 @@ module Guns
49
49
  end
50
50
  module_function :sh
51
51
 
52
- def sh!(*args)
53
- out, err, code = sh(*args)
54
- raise Failure, err if code != 0
52
+ def sh!(cmd, *args)
53
+ out, err, code = sh(cmd, *args)
54
+ cmd << " " << args.join(" ") if !args.empty?
55
+ raise Failure, "(#{cmd})\n#{err}" if code != 0
55
56
  [out, err, code]
56
57
  end
57
58
  module_function :sh!
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: guns
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Blake Mizerany