execute 0.1.10 → 0.1.11
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/cmd.rb +2 -2
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 792b072f3492decab09d816547b3124be213c101
|
4
|
+
data.tar.gz: ceaecac7539819cc201eec6019027daf36196b36
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: fe2fba3aac76f475db3491a01c64df80607e33227902c7ef87bcc13df502b6e8292e4ddf50247aeb132916661b6bf97e5fe194d0616abac7ac55cc0a7f9937b1
|
7
|
+
data.tar.gz: 5d1c9566d177ecab0d016ee47eb990fbdadbfd023496a198d2686ebecde4951a315c47b630dabbaab318ae582438e454555f2f44038badb2bf566d0ba7fd736e
|
data/lib/cmd.rb
CHANGED
@@ -43,7 +43,7 @@ class CMD < Hash
|
|
43
43
|
self[:error] = output[:error].join
|
44
44
|
self[:exit_code] = wait_thr.value.to_i
|
45
45
|
end
|
46
|
-
rescue
|
46
|
+
rescue Exception => e
|
47
47
|
self[:error] = "#{self[:error]}\nException: #{e.to_s}"
|
48
48
|
self[:exit_code]=1 unless(self[:exit_code].nil? || (self[:exit_code] == 0))
|
49
49
|
end
|
@@ -56,7 +56,7 @@ class CMD < Hash
|
|
56
56
|
end
|
57
57
|
|
58
58
|
if((self[:exit_code] != 0) && !self[:ignore_exit_code])
|
59
|
-
exception_text = "Exit code: #{self[:exit_code}"
|
59
|
+
exception_text = "Exit code: #{self[:exit_code]}"
|
60
60
|
exception_text = "#{exception_text}\n#{self[:error]}"
|
61
61
|
exception_text = "#{exception_text}\n#{self[:output]}" if(self[:error].empty?)
|
62
62
|
raise exception_text
|