revs-utils 1.0.8 → 1.0.9

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 CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- NGY1MmUzYTdjMjU1OTI2MGU5NzA0YTIzZDVkOGY0Nzg1OWYwMzZjOA==
4
+ NTIxOTA2YTJkZGRkMTY2NjU4OTE1OGVhZjIxYmNhYjVhZjE1Zjg2OA==
5
5
  data.tar.gz: !binary |-
6
- ZjQ0OWRiOTlmZGQ2YzY1YjU4Zjc1NWU3MWIyODU4NjRiMTg4Nzg5MQ==
6
+ ZjhlZTYxZDcwZTJhOTg2NDBjZmM4NTY4Njg2YmY0NWQ5ZmM2N2JmZA==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- Y2RkOTIyYTVhNmRlODRmYWViNzMwMzkyNGM3MjVmYTc1MzNjYWMyMDgyZDk0
10
- OTNiYjE2NjQ2YzJiMGY2NjA0OGNjY2UzZDdhZTc0ZWRhMjhkNWRlYmY5ZTdi
11
- M2I5NzJhMjY2OTMyYTg3NDYyZTFiYWQzYTQ3MjhiZDg5NjMxYjA=
9
+ NTlhYjZlNTViNDk5MWEzMDZkNDliMzExMzdjYzc1Njk1ZjMwN2RlYjkwZTA4
10
+ Zjk3NTlmOTYzNWUzYjEwMGIxMzI4YzI4NzNkNjhkOGY1ZWE2YmFjNmRjNTg5
11
+ MDVjYTI1ZDBiNjI2YzUyYTZlOTQ0NjJkODI0MjhiZmI3OGZkMzE=
12
12
  data.tar.gz: !binary |-
13
- MGNhMDEwMTM5Y2Q3YmNiODcxMTU5NzI3MjU5MTZkYjY4YWI1YmZmNWZhMzA0
14
- MzhjMWY0ZjExZjg3MTdlNTBiMjJjMGVjYjhhZjk5MGIwOGYxMDBhOWU1MzEz
15
- ZDUwNWNmOGU4YzEyNmI0NjY0MzM4OTEwYzgzNjJiOTVhMTQzMGI=
13
+ ZTY0Y2FkZDJjZDg3ZTk2MGJhZjc3NGQwN2YxODQ1YTE3Y2JlNGEwNjBmMGY3
14
+ NDQwZTc5ZTA2YmQzNTM4YzdjZTJiOGRmY2MyZWM2YTQ3ZjA1NGI3NWM3MTAz
15
+ MDNkMzg0MmFjZGZjODAxZGU1MWIwYTFkYTFiZmU3MjU3MTgxY2E=
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- revs-utils (1.0.8)
4
+ revs-utils (1.0.9)
5
5
  actionpack (~> 3)
6
6
  countries (= 0.9.2)
7
7
  rdf
@@ -10,9 +10,9 @@ GEM
10
10
  remote: http://rubygems.org/
11
11
  remote: http://sul-gems.stanford.edu/
12
12
  specs:
13
- actionpack (3.2.19)
14
- activemodel (= 3.2.19)
15
- activesupport (= 3.2.19)
13
+ actionpack (3.2.21)
14
+ activemodel (= 3.2.21)
15
+ activesupport (= 3.2.21)
16
16
  builder (~> 3.0.0)
17
17
  erubis (~> 2.7.0)
18
18
  journey (~> 1.0.4)
@@ -20,10 +20,10 @@ GEM
20
20
  rack-cache (~> 1.2)
21
21
  rack-test (~> 0.6.1)
22
22
  sprockets (~> 2.2.1)
23
- activemodel (3.2.19)
24
- activesupport (= 3.2.19)
23
+ activemodel (3.2.21)
24
+ activesupport (= 3.2.21)
25
25
  builder (~> 3.0.0)
26
- activesupport (3.2.19)
26
+ activesupport (3.2.21)
27
27
  i18n (~> 0.6, >= 0.6.4)
28
28
  multi_json (~> 1.0)
29
29
  builder (3.0.4)
@@ -33,7 +33,7 @@ GEM
33
33
  diff-lcs (1.2.4)
34
34
  erubis (2.7.0)
35
35
  hike (1.2.3)
36
- i18n (0.6.11)
36
+ i18n (0.7.0)
37
37
  journey (1.0.4)
38
38
  lyberteam-gems-devel (1.0.1)
39
39
  rake (>= 0.8.7)
@@ -43,10 +43,10 @@ GEM
43
43
  rack (1.4.5)
44
44
  rack-cache (1.2)
45
45
  rack (>= 0.4)
46
- rack-test (0.6.2)
46
+ rack-test (0.6.3)
47
47
  rack (>= 1.0)
48
48
  rake (10.1.0)
49
- rdf (1.1.4.1)
49
+ rdf (1.1.6)
50
50
  rest-client (1.6.7)
51
51
  mime-types (>= 1.16)
52
52
  rspec (2.14.1)
@@ -57,7 +57,7 @@ GEM
57
57
  rspec-expectations (2.14.3)
58
58
  diff-lcs (>= 1.1.3, < 2.0)
59
59
  rspec-mocks (2.14.4)
60
- sprockets (2.2.2)
60
+ sprockets (2.2.3)
61
61
  hike (~> 1.2)
62
62
  multi_json (~> 1.0)
63
63
  rack (~> 1.0)
data/README.rdoc CHANGED
@@ -18,10 +18,11 @@ Shared methods and functions used by revs-indexer, pre-assembly and bulk metadat
18
18
  - <b>1.0.6</b> Add some more conditions to CSV header checks
19
19
  - <b>1.0.7</b> Label column needs to be there but does not need to have a value to register
20
20
  - <b>1.0.8</b> Update clean_collection_name method to deal with other possible names
21
+ - <b>1.0.9</b> Add more common format corrections
21
22
 
22
23
  == Running tests
23
24
 
24
- rake spec
25
+ bundle exec rspec spec
25
26
 
26
27
  == Release the gem to the gemserver
27
28
 
@@ -29,7 +30,13 @@ rake spec
29
30
  2. Add to the release notes in this readme.
30
31
  3. Ensure the tests pass.
31
32
  4. Git commit and push
32
- 5. rake dlss_release
33
+ 5. Build the gem:
34
+
35
+ gem build revs-utils.gemspec
36
+
37
+ 6. Release the gem to RubyGems:
38
+
39
+ gem push revs-utils-1.0.9.gem # substitute actual version number
33
40
 
34
41
  == Installation
35
42
 
@@ -1,5 +1,5 @@
1
1
  module Revs
2
2
  module Utils
3
- VERSION = "1.0.8"
3
+ VERSION = "1.0.9"
4
4
  end
5
5
  end
data/lib/revs-utils.rb CHANGED
@@ -146,17 +146,22 @@ module Revs
146
146
  return row
147
147
  end
148
148
 
149
+ # check a single format single and fix some common issues
149
150
  def revs_check_format(format)
150
151
  return revs_check_formats([format]).first
151
152
  end
152
153
 
153
- # check the incoming format and fix some common issues
154
+ # check the incoming array of formats and fix some common issues
154
155
  def revs_check_formats(format)
155
156
  known_fixes = {"black-and-white negative"=>"black-and-white negatives",
156
157
  "color negative"=>"color negatives",
157
158
  "slides/color transparency"=>"color transparencies",
158
159
  "color negatives/slides"=>"color negatives",
159
160
  "black-and-white negative strips"=>"black-and-white negatives",
161
+ "black and white"=>"black-and-white negatives",
162
+ "black-and-white"=>"black-and-white negatives",
163
+ "black and white negative"=>"black-and-white negatives",
164
+ "black and white negatives"=>"black-and-white negatives",
160
165
  "color transparency"=>"color transparencies",
161
166
  "slide"=>"slides"
162
167
  }
data/revs-utils.gemspec CHANGED
@@ -11,7 +11,8 @@ Gem::Specification.new do |gem|
11
11
  gem.description = "Shared methods and functions used by revs-indexer, pre-assembly and bulk metadata loading code."
12
12
  gem.summary = "Shared methods and functions used by revs-indexer, pre-assembly and bulk metadata loading code."
13
13
  gem.homepage = ""
14
-
14
+ gem.license = "All rights reserved, Stanford University."
15
+
15
16
  gem.files = `git ls-files`.split($/)
16
17
  gem.executables = gem.files.grep(%r{^bin/}).map{ |f| File.basename(f) }
17
18
  gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
@@ -62,6 +62,7 @@ describe "Revs-Utils" do
62
62
 
63
63
  it "should clean up some common format errors from an array" do
64
64
  @revs.revs_check_formats(['black-and-white negative','color negative','leave alone']).should == ['black-and-white negatives','color negatives','leave alone']
65
+ @revs.revs_check_formats(['black and white','color negative','black-and-white negative']).should == ['black-and-white negatives','color negatives','black-and-white negatives']
65
66
  end
66
67
 
67
68
  it "should clean up some common format errors from a string" do
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: 1.0.8
4
+ version: 1.0.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Peter Mangiafico
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-10-14 00:00:00.000000000 Z
11
+ date: 2015-01-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: countries
@@ -135,7 +135,8 @@ files:
135
135
  - spec/sample-csv-files/no-sourceid.csv
136
136
  - spec/spec_helper.rb
137
137
  homepage: ''
138
- licenses: []
138
+ licenses:
139
+ - All rights reserved, Stanford University.
139
140
  metadata: {}
140
141
  post_install_message:
141
142
  rdoc_options: []
@@ -153,7 +154,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
153
154
  version: '0'
154
155
  requirements: []
155
156
  rubyforge_project:
156
- rubygems_version: 2.2.2
157
+ rubygems_version: 2.4.2
157
158
  signing_key:
158
159
  specification_version: 4
159
160
  summary: Shared methods and functions used by revs-indexer, pre-assembly and bulk