revs-utils 2.1.10 → 2.1.11
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 +8 -8
- data/Gemfile.lock +3 -3
- data/README.rdoc +2 -0
- data/config/manifest_headers.yml +4 -1
- data/files/revs-lc-marque-terms.obj +0 -0
- data/lib/revs-utils/version.rb +1 -1
- data/lib/revs-utils.rb +3 -2
- data/spec/sample-csv-files/clean-sheet.csv +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
---
|
|
2
2
|
!binary "U0hBMQ==":
|
|
3
3
|
metadata.gz: !binary |-
|
|
4
|
-
|
|
4
|
+
ZmNlOTFhOGJkN2JiMWYyYjAxZjZlNTUyNTI1MWNhY2M2N2E2NDJmNQ==
|
|
5
5
|
data.tar.gz: !binary |-
|
|
6
|
-
|
|
6
|
+
NzdjMTJjMjhhZDM4NzVlNTY3NmI5MjI5ZTdiZGU3NTVmMzA4NTg0YQ==
|
|
7
7
|
SHA512:
|
|
8
8
|
metadata.gz: !binary |-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
ODk3OTg3OTBhYzQ4MjFjZTMwN2E3YjcyNDU1YmIzYzI1MjBkMWQ5NGZmOWJm
|
|
10
|
+
Y2U3MWMzMzVkNDFmYWIyM2VmODQ0ZDA4MWNjYmE4MDQ3MDE1NzEzZmE4NDky
|
|
11
|
+
NzJkYWY3NzQ3ZjU5ZDFjZDkyZWRlZTVlYzU5NWQ2YzUxOGRmZWE=
|
|
12
12
|
data.tar.gz: !binary |-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
13
|
+
MDc0Zjc5ZmE0ZTFkYTdiNGViYWVjYzAyZWFjNWI0MmEzM2Q5ODQ0ZTdjZGEx
|
|
14
|
+
MDI2NjllOTBjM2FmMTYwNTIzOThhMTk1YTJkY2NhYTAxMzk0OTkwMWM4YmJh
|
|
15
|
+
MWQwNjkzYjg2Mjc2OGMwM2E2YzE3NWIwYjkwNDVjYjQ2Zjk5NzU=
|
data/Gemfile.lock
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
PATH
|
|
2
2
|
remote: .
|
|
3
3
|
specs:
|
|
4
|
-
revs-utils (2.1.
|
|
4
|
+
revs-utils (2.1.11)
|
|
5
5
|
actionpack (>= 4.1.6)
|
|
6
6
|
chronic
|
|
7
7
|
countries (= 0.9.2)
|
|
@@ -51,7 +51,7 @@ GEM
|
|
|
51
51
|
rest-client
|
|
52
52
|
mime-types (2.4.3)
|
|
53
53
|
mini_portile (0.6.2)
|
|
54
|
-
minitest (5.
|
|
54
|
+
minitest (5.8.0)
|
|
55
55
|
netrc (0.10.3)
|
|
56
56
|
nokogiri (1.6.6.2)
|
|
57
57
|
mini_portile (~> 0.6.0)
|
|
@@ -60,7 +60,7 @@ GEM
|
|
|
60
60
|
rack (>= 1.0)
|
|
61
61
|
rails-deprecated_sanitizer (1.0.3)
|
|
62
62
|
activesupport (>= 4.2.0.alpha)
|
|
63
|
-
rails-dom-testing (1.0.
|
|
63
|
+
rails-dom-testing (1.0.7)
|
|
64
64
|
activesupport (>= 4.2.0.beta, < 5.0)
|
|
65
65
|
nokogiri (~> 1.6.0)
|
|
66
66
|
rails-deprecated_sanitizer (>= 1.0.1)
|
data/README.rdoc
CHANGED
|
@@ -24,6 +24,8 @@ Shared methods and functions used by revs-indexer, pre-assembly and bulk metadat
|
|
|
24
24
|
- <b>2.0.4</b> Fix issues with year parsing
|
|
25
25
|
- <b>2.0.10</b> Update to latest version of actionpack
|
|
26
26
|
- <b>2.1.0 - 2.1.4</b> Add field mapping and other common methods used in both revs digital library and revs-indexing
|
|
27
|
+
- <b>2.1.10</b> Display output showing reasons for validation failures when checking manifests
|
|
28
|
+
- <b>2.1.11</b> Allow for optional metadata columns in the manifest
|
|
27
29
|
|
|
28
30
|
== Running tests
|
|
29
31
|
|
data/config/manifest_headers.yml
CHANGED
|
@@ -30,6 +30,8 @@ metadata:
|
|
|
30
30
|
hide: hide
|
|
31
31
|
format: format
|
|
32
32
|
collection_name: collection_name
|
|
33
|
+
metadata_optional:
|
|
34
|
+
format_authority: format_authority
|
|
33
35
|
known_formats:
|
|
34
36
|
- black-and-white film
|
|
35
37
|
- color film
|
|
@@ -41,4 +43,5 @@ known_formats:
|
|
|
41
43
|
- black-and-white negatives
|
|
42
44
|
- color negatives
|
|
43
45
|
- black-and-white transparencies
|
|
44
|
-
- color transparencies
|
|
46
|
+
- color transparencies
|
|
47
|
+
- Glass negatives
|
|
Binary file
|
data/lib/revs-utils/version.rb
CHANGED
data/lib/revs-utils.rb
CHANGED
|
@@ -14,6 +14,7 @@ REVS_LC_TERMS_FILENAME=File.join(PROJECT_ROOT,'files','revs-lc-marque-terms.obj'
|
|
|
14
14
|
REVS_MANIFEST_HEADERS_FILEPATH = File.join(PROJECT_ROOT,'config',"manifest_headers.yml")
|
|
15
15
|
REGISTER = "register"
|
|
16
16
|
METADATA = "metadata"
|
|
17
|
+
OPTIONAL = "metadata_optional"
|
|
17
18
|
FORMATS = "known_formats"
|
|
18
19
|
|
|
19
20
|
module Revs
|
|
@@ -22,7 +23,7 @@ module Revs
|
|
|
22
23
|
# a hash of LC Subject Heading terms and their IDs for linking for "Automobiles" http://id.loc.gov/authorities/subjects/sh85010201.html
|
|
23
24
|
# this is cached and loaded from disk and deserialized back into a hash for performance reasons, then stored as a module
|
|
24
25
|
# level constant so it can be reused throughout the pre-assembly run as a constant
|
|
25
|
-
# This cached set of terms can be re-generated with "ruby
|
|
26
|
+
# This cached set of terms can be re-generated with "ruby bin/revs_lc_automobile_terms.rb"
|
|
26
27
|
AUTOMOBILE_LC_TERMS= File.open(REVS_LC_TERMS_FILENAME,'rb'){|io| Marshal.load(io)} if File.exists?(REVS_LC_TERMS_FILENAME)
|
|
27
28
|
REVS_MANIFEST_HEADERS_FILE = File.open(REVS_MANIFEST_HEADERS_FILEPATH)
|
|
28
29
|
REVS_MANIFEST_HEADERS = YAML.load( REVS_MANIFEST_HEADERS_FILE)
|
|
@@ -229,7 +230,7 @@ module Revs
|
|
|
229
230
|
puts "has location column as well as specific state,city,country columns"
|
|
230
231
|
result2=false
|
|
231
232
|
end
|
|
232
|
-
extra_columns = file_headers-get_manifest_section(METADATA).values-get_manifest_section(REGISTER).values
|
|
233
|
+
extra_columns = file_headers-get_manifest_section(METADATA).values-get_manifest_section(REGISTER).values-get_manifest_section(OPTIONAL).values
|
|
233
234
|
has_extra_columns = (extra_columns == [])
|
|
234
235
|
puts "has unknown columns: #{extra_columns.join(', ')}" unless has_extra_columns
|
|
235
236
|
result3 = has_extra_columns
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
format,sourceid,collection_name,filename,year,photographer,label,marque,model,model_year,people,city,state,country,event,description,inst_notes,prod_notes,has_more_metadata
|
|
1
|
+
format,sourceid,collection_name,filename,year,photographer,label,marque,model,model_year,people,city,state,country,event,description,inst_notes,prod_notes,has_more_metadata,format_authority
|
|
2
2
|
black-and-white negatives,2004-100CRAI-b1_1.0_0001,Bruce R Craig Photograph Collection,2004-100CRAI-b1_1.0_0001.tif,,Bruce R Craig,Rutherford Special,Rutherford Special,,,"Rutherford, Slim",,,"full car (rear), #62",,,
|
|
3
3
|
black-and-white negatives,2004-100CRAI-b1_1.0_0002,Bruce R Craig Photograph Collection,2004-100CRAI-b1_1.0_0002.tif,,Bruce R Craig,City of Roses,City of Roses,,,"Sezekendy, Charley",,,"full car, #2",,,
|
|
4
4
|
black-and-white negatives,2004-100CRAI-b1_1.0_0003,Bruce R Craig Photograph Collection,2004-100CRAI-b1_1.0_0003.tif,,Ed Hitzwe,Wilburn | Morgan,,,,Wilburn | Morgan,,,"install tire on wheel, posed photo",,,
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: revs-utils
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 2.1.
|
|
4
|
+
version: 2.1.11
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Peter Mangiafico
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2015-09-
|
|
11
|
+
date: 2015-09-03 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: countries
|