di 0.4.1 → 0.4.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (5) hide show
  1. checksums.yaml +4 -4
  2. data/HISTORY +5 -0
  3. data/di.gemspec +1 -0
  4. data/lib/di.rb +8 -3
  5. metadata +5 -4
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 89485791b2612b6df2c0cce66f24856571c85dde
4
- data.tar.gz: 8ac703cf8b70c4ccb5a680c91f64c12f8d7c21cf
3
+ metadata.gz: 492fd8b1ee082ed8ee489760ef1d360b9f56d12a
4
+ data.tar.gz: d2e3f3b24063143f279f5bb83889ec798b64127a
5
5
  SHA512:
6
- metadata.gz: 6693cdfccee6b3787ed382feb31cd51818f548ba2e5643121920bfb81d7932632ed2ca01bb263e56d1a9c60d6a39f4077a21e988338274bb4c4baf97274d774e
7
- data.tar.gz: 032c8c70a6851bc94f2901401b454011873419dc9cc80a6ec0e2f2de2272abe555d1682529217cb6298a7f700d3ac922bd81b8a6c7d1a0524d490b0fa90df48f
6
+ metadata.gz: e0951beceb1947defd0d710a4458ef9ce6835190b00bc19e8544f6fcb0b43949e2e13972f8e11441b46373461fe8b7a9174941cc235754d6131a48583d4f3bf8
7
+ data.tar.gz: e870a6f3e215697edb356316b0ff77ddb07b98246b7974985a00ab91f305d929a5a0283e04d1ab0006bb41d82db43109d715e36bdaa20d216c1b4d3aaa20f809
data/HISTORY CHANGED
@@ -1,3 +1,8 @@
1
+ == 0.4.2 2013-08-16
2
+
3
+ * Do not close inherited file descriptors on invoking diff(1) so that
4
+ `di file <(command)` works.
5
+
1
6
  == 0.4.1 2013-04-11
2
7
 
3
8
  * Set better labels and disable pager if invoked by git difftool.
data/di.gemspec CHANGED
@@ -14,6 +14,7 @@ default settings and some original features.
14
14
  EOS
15
15
  gem.summary = %q{A wrapper around GNU diff(1)}
16
16
  gem.homepage = "https://github.com/knu/di"
17
+ gem.license = "2-clause BSDL"
17
18
 
18
19
  gem.files = `git ls-files`.split($/)
19
20
  gem.executables = gem.files.grep(%r{^bin/}).map{ |f| File.basename(f) }
data/lib/di.rb CHANGED
@@ -28,7 +28,7 @@
28
28
  # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
29
29
  # SUCH DAMAGE.
30
30
 
31
- MYVERSION = "0.4.1"
31
+ MYVERSION = "0.4.2"
32
32
  MYNAME = File.basename($0)
33
33
  MYCOPYRIGHT = "Copyright (c) 2008, 2009, 2010, 2011, 2012, 2013 Akinori MUSHA"
34
34
 
@@ -79,6 +79,11 @@ def warn(*lines)
79
79
  }
80
80
  end
81
81
 
82
+ def xsystem(*args)
83
+ args << { :close_others => false } unless RUBY_VERSION < '1.9'
84
+ system(*args)
85
+ end
86
+
82
87
  def setup
83
88
  require 'ostruct'
84
89
  $diff = OpenStruct.new({
@@ -375,7 +380,7 @@ usage: #{MYNAME} [flags] [files]
375
380
 
376
381
  ----
377
382
  EOF
378
- system(DIFF_CMD, '--version')
383
+ xsystem(DIFF_CMD, '--version')
379
384
  exit
380
385
  }
381
386
  opts.on('--help',
@@ -623,7 +628,7 @@ end
623
628
 
624
629
  def call_diff(*args)
625
630
  invoke_colorizer
626
- system *[DIFF_CMD, $diff.flags, args].flatten
631
+ xsystem *[DIFF_CMD, $diff.flags, args].flatten
627
632
  status = $? >> 8
628
633
  $status = status if $status < status
629
634
  return status
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: di
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.1
4
+ version: 0.4.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Akinori MUSHA
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-04-11 00:00:00.000000000 Z
11
+ date: 2013-08-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: diff-lcs
@@ -48,7 +48,8 @@ files:
48
48
  - test/helper.rb
49
49
  - test/test_di.rb
50
50
  homepage: https://github.com/knu/di
51
- licenses: []
51
+ licenses:
52
+ - 2-clause BSDL
52
53
  metadata: {}
53
54
  post_install_message:
54
55
  rdoc_options: []
@@ -66,7 +67,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
66
67
  version: '0'
67
68
  requirements: []
68
69
  rubyforge_project:
69
- rubygems_version: 2.0.0
70
+ rubygems_version: 2.0.3
70
71
  signing_key:
71
72
  specification_version: 4
72
73
  summary: A wrapper around GNU diff(1)