assembly-objectfile 1.8.0 → 1.8.1
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/README.rdoc +8 -4
- data/lib/assembly-objectfile/content_metadata.rb +1 -1
- data/lib/assembly-objectfile/version.rb +1 -1
- data/spec/content_metadata_spec.rb +9 -0
- metadata +4 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9340849c0c7e9473a7f64cdbc2882ced45df4b127851f7f39b2ec7617392a23d
|
4
|
+
data.tar.gz: 9b7b9240d7b66e59c25cf812da864f9ad5bed47d384138517e9f931b7f22d519
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 74bc38ddbc94dd288eaca87caa1c0e1f8f4c0f64a815adf1ec88d88b94145152cb40cbb479509ec987e450ac343d7ee7f9d693ef403c83a13c7349c7f09562a9
|
7
|
+
data.tar.gz: 467ac07058e4b354f3132e651eba1e9149ef0f7bbbd70ef77f1ab0b4d4f4fe09f39d62868879c2daa16cf4d10fe1dd532ba37bb6b9d0be9a3066aef0448e1f8b
|
data/README.rdoc
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
= Assembly-ObjectFile Gem
|
4
4
|
|
5
|
-
==Overview
|
5
|
+
==Overview
|
6
6
|
This gem contains classes used by the Stanford University Digital Library to perform
|
7
7
|
file operations necessary for accessioning of content. It is also used by related gems to perform
|
8
8
|
content type specific operations (such as jp2 generation).
|
@@ -50,7 +50,7 @@ content type specific operations (such as jp2 generation).
|
|
50
50
|
- 1.4.1 fix errors that could error if there was a space in the filename
|
51
51
|
- 1.4.2 Support map style content metadata; don't compute mimetype when generating content metadata unless its needed
|
52
52
|
- 1.4.3 object_type method should return :other if it is an unknown mimetype
|
53
|
-
- 1.4.4 produce blank content metadata if no objects are passed in
|
53
|
+
- 1.4.4 produce blank content metadata if no objects are passed in
|
54
54
|
- 1.4.5 allow the user to supply optional file specific attributes for publish, preserve, shelve for creating content metadata
|
55
55
|
- 1.4.6 add dirname attribute to objectfile class
|
56
56
|
- 1.4.7 add an additional default mimetype for file perservation attributes
|
@@ -70,6 +70,10 @@ content type specific operations (such as jp2 generation).
|
|
70
70
|
- 1.6.4 Try and solve UTF-8 encoding issues with exif data in images
|
71
71
|
- 1.6.5 Just use mime-types extension by default to compute mimetype to prevent calling to shell all the time (and avoid potential memory problems). A new method allows you to call out to shell if you really want to.
|
72
72
|
- 1.7.0 Support the `role` attribute on files
|
73
|
+
- 1.7.1 Don't produce empty XML attributes
|
74
|
+
- 1.7.2 Allow for 3d content metadata generation
|
75
|
+
- 1.8.0 Add in mime-type generation from the shell again to correctly set 3D and other mimetypes (if exif data does not exist)
|
76
|
+
- 1.8.1 Adds style to error message when style is invalid
|
73
77
|
|
74
78
|
==Usage
|
75
79
|
|
@@ -86,7 +90,7 @@ The gem currently has methods for:
|
|
86
90
|
|
87
91
|
gem build assembly-objectfile.gemspec
|
88
92
|
gem push assembly-objectfile-x.y.z.gem # replace x-y-z with the version number, you'll need a ruby gems account to do this
|
89
|
-
|
93
|
+
|
90
94
|
==Generate documentation
|
91
95
|
To generate documentation into the "doc" folder:
|
92
96
|
|
@@ -99,7 +103,7 @@ To keep a local server running with up to date code documentation that you can v
|
|
99
103
|
==Prerequisites
|
100
104
|
|
101
105
|
1. Exiftool
|
102
|
-
|
106
|
+
|
103
107
|
RHEL: (RPM to install comming soon)
|
104
108
|
Download latest version from: http://www.sno.phy.queensu.ca/~phil/exiftool
|
105
109
|
|
@@ -93,7 +93,7 @@ module Assembly
|
|
93
93
|
when :'3d'
|
94
94
|
content_type_description = content_type_descriptions[:'3d']
|
95
95
|
else
|
96
|
-
raise
|
96
|
+
raise "Supplied style (#{style}) not valid"
|
97
97
|
end
|
98
98
|
|
99
99
|
puts "WARNING - the style #{style} is now deprecated and should not be used." if DEPRECATED_STYLES.include? style
|
@@ -597,4 +597,13 @@ describe Assembly::ContentMetadata do
|
|
597
597
|
expect(xml.xpath('//resource').length).to be 0
|
598
598
|
expect(xml.xpath('//resource/file').length).to be 0
|
599
599
|
end
|
600
|
+
|
601
|
+
it 'generates an error message when an unknown style is passed in' do
|
602
|
+
objects = []
|
603
|
+
expect {
|
604
|
+
described_class.create_content_metadata(druid: TEST_DRUID, bundle: :prebundled, style: :borked, objects: objects)
|
605
|
+
}.to raise_error { |error|
|
606
|
+
expect(error.message).to eq('Supplied style (borked) not valid')
|
607
|
+
}
|
608
|
+
end
|
600
609
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: assembly-objectfile
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.8.
|
4
|
+
version: 1.8.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Peter Mangiafico
|
@@ -11,7 +11,7 @@ authors:
|
|
11
11
|
autorequire:
|
12
12
|
bindir: exe
|
13
13
|
cert_chain: []
|
14
|
-
date: 2019-08-
|
14
|
+
date: 2019-08-21 00:00:00.000000000 Z
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|
17
17
|
name: mime-types
|
@@ -224,7 +224,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
224
224
|
- !ruby/object:Gem::Version
|
225
225
|
version: '0'
|
226
226
|
requirements: []
|
227
|
-
|
227
|
+
rubyforge_project: assembly-objectfile
|
228
|
+
rubygems_version: 2.7.6
|
228
229
|
signing_key:
|
229
230
|
specification_version: 4
|
230
231
|
summary: Ruby immplementation of file services needed to prepare objects to be accessioned
|