jhove-service 1.1.4 → 1.4.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.rdoc +1 -1
- data/bin/aiff-hul-1.6.1-RC1.jar +0 -0
- data/bin/ascii-hul-1.4.1.jar +0 -0
- data/bin/cache/xhtml-attribs-1.xsd +73 -0
- data/bin/cache/xhtml-base-1.xsd +36 -0
- data/bin/cache/xhtml-bdo-1.xsd +71 -0
- data/bin/cache/xhtml-blkphras-1.xsd +160 -0
- data/bin/cache/xhtml-blkpres-1.xsd +37 -0
- data/bin/cache/xhtml-blkstruct-1.xsd +49 -0
- data/bin/cache/xhtml-csismap-1.xsd +96 -0
- data/bin/cache/xhtml-datatypes-1.xsd +242 -0
- data/bin/cache/xhtml-edit-1.xsd +39 -0
- data/bin/cache/xhtml-events-1.xsd +130 -0
- data/bin/cache/xhtml-form-1.xsd +327 -0
- data/bin/cache/xhtml-framework-1.xsd +66 -0
- data/bin/cache/xhtml-hypertext-1.xsd +47 -0
- data/bin/cache/xhtml-image-1.xsd +46 -0
- data/bin/cache/xhtml-inlphras-1.xsd +163 -0
- data/bin/cache/xhtml-inlpres-1.xsd +39 -0
- data/bin/cache/xhtml-inlstruct-1.xsd +50 -0
- data/bin/cache/xhtml-inlstyle-1.xsd +27 -0
- data/bin/cache/xhtml-link-1.xsd +45 -0
- data/bin/cache/xhtml-list-1.xsd +99 -0
- data/bin/cache/xhtml-meta-1.xsd +54 -0
- data/bin/cache/xhtml-object-1.xsd +76 -0
- data/bin/cache/xhtml-param-1.xsd +51 -0
- data/bin/cache/xhtml-pres-1.xsd +51 -0
- data/bin/cache/xhtml-ruby-1.xsd +170 -0
- data/bin/cache/xhtml-script-1.xsd +71 -0
- data/bin/cache/xhtml-ssismap-1.xsd +43 -0
- data/bin/cache/xhtml-struct-1.xsd +130 -0
- data/bin/cache/xhtml-style-1.xsd +53 -0
- data/bin/cache/xhtml-table-1.xsd +272 -0
- data/bin/cache/xhtml-target-1.xsd +49 -0
- data/bin/cache/xhtml-text-1.xsd +67 -0
- data/bin/cache/xhtml11-model-1.xsd +716 -0
- data/bin/cache/xhtml11-modules-1.xsd +605 -0
- data/bin/cache/xhtml11.xsd +104 -0
- data/bin/cache/xml.xsd +287 -0
- data/bin/gif-hul-1.4.2-RC1.jar +0 -0
- data/bin/html-hul-1.4.1.jar +0 -0
- data/bin/jhove-apps-1.24.0-RC1.jar +0 -0
- data/bin/jhove-ext-modules-1.24.0-RC1.jar +0 -0
- data/bin/jhove.conf +40 -2
- data/bin/jhoveToolkit.sh +36 -4
- data/bin/jpeg-hul-1.5.2-RC1.jar +0 -0
- data/bin/jpeg2000-hul-1.4.2-RC1.jar +0 -0
- data/bin/pdf-hul-1.12.2-RC1.jar +0 -0
- data/bin/tiff-hul-1.9.2-RC1.jar +0 -0
- data/bin/utf8-hul-1.7.1.jar +0 -0
- data/bin/wave-hul-1.8.1-RC1.jar +0 -0
- data/bin/xml-hul-1.5.1.jar +0 -0
- data/lib/jhove_service.rb +7 -8
- metadata +55 -8
- data/bin/jhove-apps-1.14.6.jar +0 -0
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
data/lib/jhove_service.rb
CHANGED
@@ -4,8 +4,9 @@ require 'jhove_technical_metadata'
|
|
4
4
|
require 'stringio'
|
5
5
|
require 'uri'
|
6
6
|
require 'shellwords'
|
7
|
+
require 'open3'
|
7
8
|
|
8
|
-
|
9
|
+
class JhoveService
|
9
10
|
|
10
11
|
# @return [Pathname] The directory in which program files are located
|
11
12
|
attr_accessor :bin_pathname
|
@@ -63,12 +64,10 @@ require 'shellwords'
|
|
63
64
|
end
|
64
65
|
|
65
66
|
# @param command [String] the command to execute on the command line
|
66
|
-
# @
|
67
|
+
# @raises [RuntimeError] if there is a problem running the command
|
67
68
|
def exec_command(command)
|
68
|
-
|
69
|
-
|
70
|
-
raise "Error when running JHOVE #{command}" if (exitcode != 0)
|
71
|
-
exitcode
|
69
|
+
stdout, stderr, status = Open3.capture3(command, chdir: @bin_pathname)
|
70
|
+
raise "Error when running JHOVE #{command}:\n#{stderr}" unless status.success?
|
72
71
|
end
|
73
72
|
|
74
73
|
# @param input_path [Pathname,String] the directory path or filename containing the folder or file to be analyzed by JHOVE
|
@@ -77,7 +76,7 @@ require 'shellwords'
|
|
77
76
|
def get_jhove_command(input_path,output_file = jhove_output)
|
78
77
|
filename = Shellwords.escape(input_path) # escape any special characters in the path
|
79
78
|
args = "-h xml -o \"#{output_file}\" \\\"#{filename}"
|
80
|
-
jhove_script =
|
79
|
+
jhove_script = './jhoveToolkit.sh'
|
81
80
|
jhove_cmd = "#{jhove_script} #{args}"
|
82
81
|
jhove_cmd
|
83
82
|
end
|
@@ -85,7 +84,7 @@ require 'shellwords'
|
|
85
84
|
# @param jhove_output_xml_ng [ng_xml_obj] the nokogiri xml output from jhove
|
86
85
|
# @param path [String] the shared path that will be removed from each file name to ensure the file nodes are relative
|
87
86
|
def remove_path_from_file_nodes(jhove_output_xml_ng,path)
|
88
|
-
jhove_output_xml_ng.xpath('//jhove:repInfo', 'jhove' => 'http://
|
87
|
+
jhove_output_xml_ng.xpath('//jhove:repInfo', 'jhove' => 'http://schema.openpreservation.org/ois/xml/ns/jhove').each do |filename_node|
|
89
88
|
filename_node.attributes['uri'].value = URI.decode(filename_node.attributes['uri'].value.gsub("#{path}",'').sub(/^\//,'')) # decode and remove path and any leading /
|
90
89
|
end
|
91
90
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jhove-service
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1
|
4
|
+
version: 1.4.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Richard Anderson
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2020-07-21 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: nokogiri
|
@@ -81,7 +81,7 @@ dependencies:
|
|
81
81
|
- - ">="
|
82
82
|
- !ruby/object:Gem::Version
|
83
83
|
version: '0'
|
84
|
-
description: Generates JHOVE output and/or technicalMetadata
|
84
|
+
description: "[DEPRECATED] Generates JHOVE output and/or technicalMetadata"
|
85
85
|
email:
|
86
86
|
- rnanders@stanford.edu
|
87
87
|
- petucket@stanford.edu
|
@@ -91,15 +91,63 @@ extra_rdoc_files: []
|
|
91
91
|
files:
|
92
92
|
- LICENSE.rdoc
|
93
93
|
- README.rdoc
|
94
|
+
- bin/aiff-hul-1.6.1-RC1.jar
|
95
|
+
- bin/ascii-hul-1.4.1.jar
|
96
|
+
- bin/cache/xhtml-attribs-1.xsd
|
97
|
+
- bin/cache/xhtml-base-1.xsd
|
98
|
+
- bin/cache/xhtml-bdo-1.xsd
|
99
|
+
- bin/cache/xhtml-blkphras-1.xsd
|
100
|
+
- bin/cache/xhtml-blkpres-1.xsd
|
101
|
+
- bin/cache/xhtml-blkstruct-1.xsd
|
102
|
+
- bin/cache/xhtml-csismap-1.xsd
|
103
|
+
- bin/cache/xhtml-datatypes-1.xsd
|
104
|
+
- bin/cache/xhtml-edit-1.xsd
|
105
|
+
- bin/cache/xhtml-events-1.xsd
|
106
|
+
- bin/cache/xhtml-form-1.xsd
|
107
|
+
- bin/cache/xhtml-framework-1.xsd
|
108
|
+
- bin/cache/xhtml-hypertext-1.xsd
|
109
|
+
- bin/cache/xhtml-image-1.xsd
|
110
|
+
- bin/cache/xhtml-inlphras-1.xsd
|
111
|
+
- bin/cache/xhtml-inlpres-1.xsd
|
112
|
+
- bin/cache/xhtml-inlstruct-1.xsd
|
113
|
+
- bin/cache/xhtml-inlstyle-1.xsd
|
114
|
+
- bin/cache/xhtml-link-1.xsd
|
115
|
+
- bin/cache/xhtml-list-1.xsd
|
116
|
+
- bin/cache/xhtml-meta-1.xsd
|
117
|
+
- bin/cache/xhtml-object-1.xsd
|
118
|
+
- bin/cache/xhtml-param-1.xsd
|
119
|
+
- bin/cache/xhtml-pres-1.xsd
|
120
|
+
- bin/cache/xhtml-ruby-1.xsd
|
121
|
+
- bin/cache/xhtml-script-1.xsd
|
122
|
+
- bin/cache/xhtml-ssismap-1.xsd
|
123
|
+
- bin/cache/xhtml-struct-1.xsd
|
124
|
+
- bin/cache/xhtml-style-1.xsd
|
125
|
+
- bin/cache/xhtml-table-1.xsd
|
126
|
+
- bin/cache/xhtml-target-1.xsd
|
127
|
+
- bin/cache/xhtml-text-1.xsd
|
128
|
+
- bin/cache/xhtml11-model-1.xsd
|
129
|
+
- bin/cache/xhtml11-modules-1.xsd
|
130
|
+
- bin/cache/xhtml11.xsd
|
131
|
+
- bin/cache/xml.xsd
|
94
132
|
- bin/console
|
95
133
|
- bin/extension-mimetype.conf
|
134
|
+
- bin/gif-hul-1.4.2-RC1.jar
|
135
|
+
- bin/html-hul-1.4.1.jar
|
96
136
|
- bin/jhove-README-1st.txt
|
97
|
-
- bin/jhove-apps-1.
|
137
|
+
- bin/jhove-apps-1.24.0-RC1.jar
|
138
|
+
- bin/jhove-ext-modules-1.24.0-RC1.jar
|
98
139
|
- bin/jhove.conf
|
99
140
|
- bin/jhoveToolkit.sh
|
141
|
+
- bin/jpeg-hul-1.5.2-RC1.jar
|
142
|
+
- bin/jpeg2000-hul-1.4.2-RC1.jar
|
143
|
+
- bin/pdf-hul-1.12.2-RC1.jar
|
144
|
+
- bin/tiff-hul-1.9.2-RC1.jar
|
145
|
+
- bin/utf8-hul-1.7.1.jar
|
146
|
+
- bin/wave-hul-1.8.1-RC1.jar
|
147
|
+
- bin/xml-hul-1.5.1.jar
|
100
148
|
- lib/jhove_service.rb
|
101
149
|
- lib/jhove_technical_metadata.rb
|
102
|
-
homepage:
|
150
|
+
homepage: http://github.com/sul-dlss/jhove-service
|
103
151
|
licenses: []
|
104
152
|
metadata: {}
|
105
153
|
post_install_message:
|
@@ -117,9 +165,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
117
165
|
- !ruby/object:Gem::Version
|
118
166
|
version: 1.3.6
|
119
167
|
requirements: []
|
120
|
-
|
121
|
-
rubygems_version: 2.7.6
|
168
|
+
rubygems_version: 3.0.8
|
122
169
|
signing_key:
|
123
170
|
specification_version: 4
|
124
|
-
summary: Generates JHOVE output and/or technicalMetadata
|
171
|
+
summary: "[DEPRECATED] Generates JHOVE output and/or technicalMetadata"
|
125
172
|
test_files: []
|
data/bin/jhove-apps-1.14.6.jar
DELETED
Binary file
|