di 0.4.3 → 0.4.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/HISTORY +5 -0
- data/LICENSE +1 -1
- data/lib/di.rb +15 -4
- metadata +6 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 38a6ebb27f63c158a2281c8084a8b7e9f863c0694a27c65e046041dd417cb513
|
4
|
+
data.tar.gz: '05084a0031eb646d6250c9d479f23b8f438ac1ce6106f6c1b32d28fd4d02590b'
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d410883c4714053d447fb99d320ebc5f451b3fab559f65b782e4d31d5885c6960b269e000377c0738c895063a93cadbecfb772aa7997acb4af300766ee14089c
|
7
|
+
data.tar.gz: e880ee0456c03170f1ca9276ee50864366b773bfa0b6182f1692251e5ae8438878fb3b06174ffc4ba22037fbfe9bae2ba04d37615133bc2976aa82089a8d6f5d
|
data/HISTORY
CHANGED
data/LICENSE
CHANGED
data/lib/di.rb
CHANGED
@@ -3,7 +3,7 @@
|
|
3
3
|
#
|
4
4
|
# di - a wrapper around GNU diff(1)
|
5
5
|
#
|
6
|
-
# Copyright (c) 2008-
|
6
|
+
# Copyright (c) 2008-2021 Akinori MUSHA
|
7
7
|
#
|
8
8
|
# All rights reserved.
|
9
9
|
#
|
@@ -28,9 +28,9 @@
|
|
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.
|
31
|
+
MYVERSION = "0.4.4"
|
32
32
|
MYNAME = File.basename($0)
|
33
|
-
MYCOPYRIGHT = "Copyright (c) 2008-
|
33
|
+
MYCOPYRIGHT = "Copyright (c) 2008-2021 Akinori MUSHA"
|
34
34
|
|
35
35
|
DIFF_CMD = ENV.fetch('DIFF', 'diff')
|
36
36
|
ENV_NAME = "#{MYNAME.tr('-a-z', '_A-Z')}_OPTIONS"
|
@@ -431,8 +431,9 @@ EOS
|
|
431
431
|
|
432
432
|
opts.parse!(args)
|
433
433
|
|
434
|
+
# -U3 must come before -p, otherwise you get "error: conflicting output format options."
|
434
435
|
$diff.format_flags.each { |format_flag|
|
435
|
-
|
436
|
+
prepend_flag(*format_flag)
|
436
437
|
}
|
437
438
|
|
438
439
|
if $diff.ignore_cvs_lines
|
@@ -535,6 +536,16 @@ def invoke_colorizer!
|
|
535
536
|
}
|
536
537
|
end
|
537
538
|
|
539
|
+
def prepend_flag(flag, val)
|
540
|
+
case val
|
541
|
+
when true, false
|
542
|
+
$diff.flags.reject! { |f,| f == flag }
|
543
|
+
$diff.flags.unshift [flag] if val
|
544
|
+
else
|
545
|
+
$diff.flags.unshift [flag, val]
|
546
|
+
end
|
547
|
+
end
|
548
|
+
|
538
549
|
def set_flag(flag, val)
|
539
550
|
case val
|
540
551
|
when true, false
|
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.
|
4
|
+
version: 0.4.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Akinori MUSHA
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-04-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: diff-lcs
|
@@ -51,7 +51,7 @@ homepage: https://github.com/knu/di
|
|
51
51
|
licenses:
|
52
52
|
- 2-clause BSDL
|
53
53
|
metadata: {}
|
54
|
-
post_install_message:
|
54
|
+
post_install_message:
|
55
55
|
rdoc_options: []
|
56
56
|
require_paths:
|
57
57
|
- lib
|
@@ -66,12 +66,10 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
66
66
|
- !ruby/object:Gem::Version
|
67
67
|
version: '0'
|
68
68
|
requirements: []
|
69
|
-
|
70
|
-
|
71
|
-
signing_key:
|
69
|
+
rubygems_version: 3.0.3
|
70
|
+
signing_key:
|
72
71
|
specification_version: 4
|
73
72
|
summary: A wrapper around GNU diff(1)
|
74
73
|
test_files:
|
75
74
|
- test/helper.rb
|
76
75
|
- test/test_di.rb
|
77
|
-
has_rdoc:
|