multi_exiftool 0.16.0 → 0.17.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/Changelog +4 -0
- data/lib/multi_exiftool/values.rb +5 -1
- data/lib/multi_exiftool.rb +1 -1
- data/multi_exiftool.gemspec +4 -4
- data/test/data/example.config +1 -1
- data/test/test_functional_api.rb +4 -4
- data/test/test_reader.rb +3 -3
- data/test/test_values.rb +6 -0
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2053e8c04690c5e8d32f19dd323c2cfbd73719ca0b4046dfa2ab5f6a460a29ef
|
4
|
+
data.tar.gz: be1df1fd8128b1907c40673c80edec623e3c95639be8938cb01bf3db1474133e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: afa561c8c911fa20bd98501e54bc95c958a9f29b4753fce76942865622e7c6f6a7c599c06da654d328f769893fbd3205b335359fc1e01695f1a8c9d7f53a62c3
|
7
|
+
data.tar.gz: b3ab0b48315d92dcea8f13aa5eb48c1b4e512df92622cf3857747c44c0dbb46dde1b582fb2133e583bc0fe81daeef3ba8b326c5250ef342b01f46bc88cfe846f
|
data/Changelog
CHANGED
@@ -55,7 +55,11 @@ module MultiExiftool
|
|
55
55
|
second = $6.to_f
|
56
56
|
zone = $7
|
57
57
|
zone = '+00:00' if zone == 'Z'
|
58
|
-
|
58
|
+
begin
|
59
|
+
Time.new(year, month, day, hour, minute, second, zone)
|
60
|
+
rescue ArgumentError
|
61
|
+
val
|
62
|
+
end
|
59
63
|
when REGEXP_RATIONAL
|
60
64
|
return val if $2.to_i == 0
|
61
65
|
Rational($1, $2)
|
data/lib/multi_exiftool.rb
CHANGED
data/multi_exiftool.gemspec
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
# -*- encoding: utf-8 -*-
|
2
|
-
# stub: multi_exiftool 0.
|
2
|
+
# stub: multi_exiftool 0.17.0 ruby lib
|
3
3
|
#
|
4
4
|
# This file is automatically generated by rim.
|
5
5
|
# PLEASE DO NOT EDIT IT DIRECTLY!
|
@@ -7,12 +7,12 @@
|
|
7
7
|
|
8
8
|
Gem::Specification.new do |s|
|
9
9
|
s.name = "multi_exiftool"
|
10
|
-
s.version = "0.
|
10
|
+
s.version = "0.17.0"
|
11
11
|
|
12
12
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
13
13
|
s.require_paths = ["lib"]
|
14
14
|
s.authors = ["Jan Friedrich"]
|
15
|
-
s.date = "
|
15
|
+
s.date = "2022-02-08"
|
16
16
|
s.description = "This library is a wrapper for the ExifTool command-line application (https://exiftool.org) written by Phil Harvey. It is designed for dealing with multiple files at once by creating commands to call exiftool with various arguments, call it and parsing the results."
|
17
17
|
s.email = "janfri26@gmail.com"
|
18
18
|
s.files = ["./.aspell.pws", "Changelog", "Gemfile", "LICENSE", "README.md", "Rakefile", "lib/multi_exiftool", "lib/multi_exiftool.rb", "lib/multi_exiftool/batch.rb", "lib/multi_exiftool/executable.rb", "lib/multi_exiftool/reader.rb", "lib/multi_exiftool/values.rb", "lib/multi_exiftool/writer.rb", "multi_exiftool.gemspec", "regtest/read_all_tags.rb", "regtest/read_all_tags.yml", "regtest/test.jpg", "test/data", "test/data/a.jpg", "test/data/b.jpg", "test/data/c.jpg", "test/data/example.config", "test/helper.rb", "test/test_batch.rb", "test/test_executable.rb", "test/test_exiftool_stuff.rb", "test/test_functional_api.rb", "test/test_reader.rb", "test/test_values.rb", "test/test_values_using_groups.rb", "test/test_writer.rb", "test/test_writer_groups.rb"]
|
@@ -21,7 +21,7 @@ Gem::Specification.new do |s|
|
|
21
21
|
s.post_install_message = "\n+-----------------------------------------------------------------------+\n| Please ensure you have installed exiftool version 7.65 or higher and |\n| it's found in your PATH (Try \"exiftool -ver\" on your commandline). |\n| For more details see |\n| https://exiftool.org/install.html |\n+-----------------------------------------------------------------------+\n "
|
22
22
|
s.required_ruby_version = Gem::Requirement.new(">= 1.9.1")
|
23
23
|
s.requirements = ["exiftool, version 7.65 or higher"]
|
24
|
-
s.rubygems_version = "3.
|
24
|
+
s.rubygems_version = "3.2.15"
|
25
25
|
s.summary = "This library is a wrapper for the ExifTool command-line application (https://exiftool.org)."
|
26
26
|
|
27
27
|
if s.respond_to? :specification_version then
|
data/test/data/example.config
CHANGED
@@ -167,7 +167,7 @@
|
|
167
167
|
# specified, then at least one of the Desire'd tags must exist. See
|
168
168
|
# the Composite table in Image::ExifTool::Exif for more examples,
|
169
169
|
# and lib/Image/ExifTool/README for all of the details.
|
170
|
-
|
170
|
+
MyBaseName => {
|
171
171
|
Require => {
|
172
172
|
0 => 'FileName',
|
173
173
|
},
|
data/test/test_functional_api.rb
CHANGED
@@ -62,12 +62,12 @@ class TestFunctionalApi < Test::Unit::TestCase
|
|
62
62
|
|
63
63
|
test 'successful reading with user defined tags in config file' do
|
64
64
|
run_in_temp_dir do
|
65
|
-
values, errors = MultiExiftool.read(%w[a.jpg b.jpg c.jpg], tags: %w[
|
66
|
-
assert_equal [nil, nil, nil], values.map(&:
|
65
|
+
values, errors = MultiExiftool.read(%w[a.jpg b.jpg c.jpg], tags: %w[mybasename fileextension])
|
66
|
+
assert_equal [nil, nil, nil], values.map(&:mybasename)
|
67
67
|
assert_equal [nil, nil, nil], values.map(&:file_extension)
|
68
68
|
assert_equal [], errors
|
69
|
-
values, errors = MultiExiftool.read(%w[a.jpg b.jpg c.jpg], config: 'example.config', tags: %w[
|
70
|
-
assert_equal %w[a b c], values.map(&:
|
69
|
+
values, errors = MultiExiftool.read(%w[a.jpg b.jpg c.jpg], config: 'example.config', tags: %w[mybasename fileextension])
|
70
|
+
assert_equal %w[a b c], values.map(&:mybasename)
|
71
71
|
assert_equal %w[jpg]*3, values.map(&:file_extension)
|
72
72
|
assert_equal [], errors
|
73
73
|
end
|
data/test/test_reader.rb
CHANGED
@@ -160,13 +160,13 @@ class TestReader < Test::Unit::TestCase
|
|
160
160
|
test 'successful reading with user defined tags in config file' do
|
161
161
|
run_in_temp_dir do
|
162
162
|
@reader.filenames = %w(a.jpg b.jpg c.jpg)
|
163
|
-
@reader.tags = %w[
|
163
|
+
@reader.tags = %w[mybasename]
|
164
164
|
res = @reader.read
|
165
|
-
assert_equal [nil, nil, nil], res.map(&:
|
165
|
+
assert_equal [nil, nil, nil], res.map(&:mybasename)
|
166
166
|
assert_equal [], @reader.errors
|
167
167
|
@reader.config = 'example.config'
|
168
168
|
res = @reader.read
|
169
|
-
assert_equal %w[a b c], res.map(&:
|
169
|
+
assert_equal %w[a b c], res.map(&:mybasename)
|
170
170
|
assert_equal [], @reader.errors
|
171
171
|
end
|
172
172
|
end
|
data/test/test_values.rb
CHANGED
@@ -120,6 +120,12 @@ class TestValues < Test::Unit::TestCase
|
|
120
120
|
assert_nil values['TimeWithOnlyZeros']
|
121
121
|
end
|
122
122
|
|
123
|
+
test 'timestamp with invalid data' do
|
124
|
+
ts = '2022:25:01 16:25'
|
125
|
+
values = MultiExiftool::Values.new('InvalidTimestamp' => ts)
|
126
|
+
assert_equal ts, values['InvalidTimestamp']
|
127
|
+
end
|
128
|
+
|
123
129
|
test 'rational with denominator zero' do
|
124
130
|
values = MultiExiftool::Values.new('DenominatorZero' => '1/0')
|
125
131
|
assert_equal '1/0', values['DenominatorZero']
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: multi_exiftool
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.17.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jan Friedrich
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2022-02-08 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|
@@ -144,7 +144,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
144
144
|
version: '0'
|
145
145
|
requirements:
|
146
146
|
- exiftool, version 7.65 or higher
|
147
|
-
rubygems_version: 3.
|
147
|
+
rubygems_version: 3.2.15
|
148
148
|
signing_key:
|
149
149
|
specification_version: 4
|
150
150
|
summary: This library is a wrapper for the ExifTool command-line application (https://exiftool.org).
|