toccatore 0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (30) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +50 -0
  3. data/.travis.yml +19 -0
  4. data/CHANGELOG.md +5 -0
  5. data/Gemfile +3 -0
  6. data/Gemfile.lock +110 -0
  7. data/LICENSE.md +21 -0
  8. data/README.md +28 -0
  9. data/bin/toccatore +5 -0
  10. data/lib/toccatore.rb +1 -0
  11. data/lib/toccatore/base.rb +361 -0
  12. data/lib/toccatore/cli.rb +38 -0
  13. data/lib/toccatore/orcid_update.rb +56 -0
  14. data/lib/toccatore/version.rb +3 -0
  15. data/spec/cli_spec.rb +29 -0
  16. data/spec/fixtures/orcid_update.json +1015 -0
  17. data/spec/fixtures/orcid_update_nil.json +12 -0
  18. data/spec/fixtures/vcr_cassettes/Toccatore_CLI/orcid_update/should_fail.yml +149 -0
  19. data/spec/fixtures/vcr_cassettes/Toccatore_CLI/orcid_update/should_succeed.yml +3453 -0
  20. data/spec/fixtures/vcr_cassettes/Toccatore_OrcidUpdate/get_data/should_report_if_there_are_no_works_returned_by_the_Datacite_Metadata_Search_API.yml +38 -0
  21. data/spec/fixtures/vcr_cassettes/Toccatore_OrcidUpdate/get_data/should_report_if_there_are_works_returned_by_the_Datacite_Metadata_Search_API.yml +149 -0
  22. data/spec/fixtures/vcr_cassettes/Toccatore_OrcidUpdate/get_total/with_no_works.yml +38 -0
  23. data/spec/fixtures/vcr_cassettes/Toccatore_OrcidUpdate/get_total/with_works.yml +38 -0
  24. data/spec/fixtures/vcr_cassettes/Toccatore_OrcidUpdate/push_data/should_report_if_there_are_works_returned_by_the_Datacite_Metadata_Search_API.yml +3307 -0
  25. data/spec/fixtures/vcr_cassettes/Toccatore_OrcidUpdate/queue_jobs/should_report_if_there_are_no_works_returned_by_the_Datacite_Metadata_Search_API.yml +38 -0
  26. data/spec/fixtures/vcr_cassettes/Toccatore_OrcidUpdate/queue_jobs/should_report_if_there_are_works_returned_by_the_Datacite_Metadata_Search_API.yml +236 -0
  27. data/spec/orcid_update_spec.rb +120 -0
  28. data/spec/spec_helper.rb +91 -0
  29. data/toccatore.gemspec +37 -0
  30. metadata +314 -0
@@ -0,0 +1,37 @@
1
+ require "date"
2
+ require File.expand_path("../lib/toccatore/version", __FILE__)
3
+
4
+ Gem::Specification.new do |s|
5
+ s.authors = "Martin Fenner"
6
+ s.email = "mfenner@datacite.org"
7
+ s.name = "toccatore"
8
+ s.homepage = "https://github.com/datacite/toccatore"
9
+ s.summary = "Ruby library to find ORCID IDs in the DataCite Solr index"
10
+ s.date = Date.today
11
+ s.description = "Ruby library to find ORCID IDs in the DataCite Solr index."
12
+ s.require_paths = ["lib"]
13
+ s.version = Toccatore::VERSION
14
+ s.extra_rdoc_files = ["README.md"]
15
+ s.license = 'MIT'
16
+
17
+ # Declary dependencies here, rather than in the Gemfile
18
+ s.add_dependency 'maremma', '~> 3.1'
19
+ s.add_dependency 'activesupport', '~> 4.2', '>= 4.2.5'
20
+ s.add_dependency 'dotenv', '~> 2.1', '>= 2.1.1'
21
+ s.add_dependency 'namae', '~> 0.11.0'
22
+ s.add_dependency 'gender_detector', '~> 1.0'
23
+ s.add_dependency 'thor', '~> 0.19'
24
+ s.add_development_dependency 'bundler', '~> 1.0'
25
+ s.add_development_dependency 'rspec', '~> 3.4'
26
+ s.add_development_dependency 'rake', '~> 12.0'
27
+ s.add_development_dependency 'rack-test', '~> 0'
28
+ s.add_development_dependency 'vcr', '~> 3.0', '>= 3.0.3'
29
+ s.add_development_dependency 'webmock', '~> 1.22', '>= 1.22.3'
30
+ s.add_development_dependency 'codeclimate-test-reporter', '~> 1.0', '>= 1.0.0'
31
+ s.add_development_dependency 'simplecov', '~> 0.12.0'
32
+
33
+ s.require_paths = ["lib"]
34
+ s.files = `git ls-files`.split($/)
35
+ s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
36
+ s.executables = ["toccatore"]
37
+ end
metadata ADDED
@@ -0,0 +1,314 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: toccatore
3
+ version: !ruby/object:Gem::Version
4
+ version: '0.1'
5
+ platform: ruby
6
+ authors:
7
+ - Martin Fenner
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2017-01-30 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: maremma
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '3.1'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '3.1'
27
+ - !ruby/object:Gem::Dependency
28
+ name: activesupport
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '4.2'
34
+ - - ">="
35
+ - !ruby/object:Gem::Version
36
+ version: 4.2.5
37
+ type: :runtime
38
+ prerelease: false
39
+ version_requirements: !ruby/object:Gem::Requirement
40
+ requirements:
41
+ - - "~>"
42
+ - !ruby/object:Gem::Version
43
+ version: '4.2'
44
+ - - ">="
45
+ - !ruby/object:Gem::Version
46
+ version: 4.2.5
47
+ - !ruby/object:Gem::Dependency
48
+ name: dotenv
49
+ requirement: !ruby/object:Gem::Requirement
50
+ requirements:
51
+ - - "~>"
52
+ - !ruby/object:Gem::Version
53
+ version: '2.1'
54
+ - - ">="
55
+ - !ruby/object:Gem::Version
56
+ version: 2.1.1
57
+ type: :runtime
58
+ prerelease: false
59
+ version_requirements: !ruby/object:Gem::Requirement
60
+ requirements:
61
+ - - "~>"
62
+ - !ruby/object:Gem::Version
63
+ version: '2.1'
64
+ - - ">="
65
+ - !ruby/object:Gem::Version
66
+ version: 2.1.1
67
+ - !ruby/object:Gem::Dependency
68
+ name: namae
69
+ requirement: !ruby/object:Gem::Requirement
70
+ requirements:
71
+ - - "~>"
72
+ - !ruby/object:Gem::Version
73
+ version: 0.11.0
74
+ type: :runtime
75
+ prerelease: false
76
+ version_requirements: !ruby/object:Gem::Requirement
77
+ requirements:
78
+ - - "~>"
79
+ - !ruby/object:Gem::Version
80
+ version: 0.11.0
81
+ - !ruby/object:Gem::Dependency
82
+ name: gender_detector
83
+ requirement: !ruby/object:Gem::Requirement
84
+ requirements:
85
+ - - "~>"
86
+ - !ruby/object:Gem::Version
87
+ version: '1.0'
88
+ type: :runtime
89
+ prerelease: false
90
+ version_requirements: !ruby/object:Gem::Requirement
91
+ requirements:
92
+ - - "~>"
93
+ - !ruby/object:Gem::Version
94
+ version: '1.0'
95
+ - !ruby/object:Gem::Dependency
96
+ name: thor
97
+ requirement: !ruby/object:Gem::Requirement
98
+ requirements:
99
+ - - "~>"
100
+ - !ruby/object:Gem::Version
101
+ version: '0.19'
102
+ type: :runtime
103
+ prerelease: false
104
+ version_requirements: !ruby/object:Gem::Requirement
105
+ requirements:
106
+ - - "~>"
107
+ - !ruby/object:Gem::Version
108
+ version: '0.19'
109
+ - !ruby/object:Gem::Dependency
110
+ name: bundler
111
+ requirement: !ruby/object:Gem::Requirement
112
+ requirements:
113
+ - - "~>"
114
+ - !ruby/object:Gem::Version
115
+ version: '1.0'
116
+ type: :development
117
+ prerelease: false
118
+ version_requirements: !ruby/object:Gem::Requirement
119
+ requirements:
120
+ - - "~>"
121
+ - !ruby/object:Gem::Version
122
+ version: '1.0'
123
+ - !ruby/object:Gem::Dependency
124
+ name: rspec
125
+ requirement: !ruby/object:Gem::Requirement
126
+ requirements:
127
+ - - "~>"
128
+ - !ruby/object:Gem::Version
129
+ version: '3.4'
130
+ type: :development
131
+ prerelease: false
132
+ version_requirements: !ruby/object:Gem::Requirement
133
+ requirements:
134
+ - - "~>"
135
+ - !ruby/object:Gem::Version
136
+ version: '3.4'
137
+ - !ruby/object:Gem::Dependency
138
+ name: rake
139
+ requirement: !ruby/object:Gem::Requirement
140
+ requirements:
141
+ - - "~>"
142
+ - !ruby/object:Gem::Version
143
+ version: '12.0'
144
+ type: :development
145
+ prerelease: false
146
+ version_requirements: !ruby/object:Gem::Requirement
147
+ requirements:
148
+ - - "~>"
149
+ - !ruby/object:Gem::Version
150
+ version: '12.0'
151
+ - !ruby/object:Gem::Dependency
152
+ name: rack-test
153
+ requirement: !ruby/object:Gem::Requirement
154
+ requirements:
155
+ - - "~>"
156
+ - !ruby/object:Gem::Version
157
+ version: '0'
158
+ type: :development
159
+ prerelease: false
160
+ version_requirements: !ruby/object:Gem::Requirement
161
+ requirements:
162
+ - - "~>"
163
+ - !ruby/object:Gem::Version
164
+ version: '0'
165
+ - !ruby/object:Gem::Dependency
166
+ name: vcr
167
+ requirement: !ruby/object:Gem::Requirement
168
+ requirements:
169
+ - - "~>"
170
+ - !ruby/object:Gem::Version
171
+ version: '3.0'
172
+ - - ">="
173
+ - !ruby/object:Gem::Version
174
+ version: 3.0.3
175
+ type: :development
176
+ prerelease: false
177
+ version_requirements: !ruby/object:Gem::Requirement
178
+ requirements:
179
+ - - "~>"
180
+ - !ruby/object:Gem::Version
181
+ version: '3.0'
182
+ - - ">="
183
+ - !ruby/object:Gem::Version
184
+ version: 3.0.3
185
+ - !ruby/object:Gem::Dependency
186
+ name: webmock
187
+ requirement: !ruby/object:Gem::Requirement
188
+ requirements:
189
+ - - "~>"
190
+ - !ruby/object:Gem::Version
191
+ version: '1.22'
192
+ - - ">="
193
+ - !ruby/object:Gem::Version
194
+ version: 1.22.3
195
+ type: :development
196
+ prerelease: false
197
+ version_requirements: !ruby/object:Gem::Requirement
198
+ requirements:
199
+ - - "~>"
200
+ - !ruby/object:Gem::Version
201
+ version: '1.22'
202
+ - - ">="
203
+ - !ruby/object:Gem::Version
204
+ version: 1.22.3
205
+ - !ruby/object:Gem::Dependency
206
+ name: codeclimate-test-reporter
207
+ requirement: !ruby/object:Gem::Requirement
208
+ requirements:
209
+ - - "~>"
210
+ - !ruby/object:Gem::Version
211
+ version: '1.0'
212
+ - - ">="
213
+ - !ruby/object:Gem::Version
214
+ version: 1.0.0
215
+ type: :development
216
+ prerelease: false
217
+ version_requirements: !ruby/object:Gem::Requirement
218
+ requirements:
219
+ - - "~>"
220
+ - !ruby/object:Gem::Version
221
+ version: '1.0'
222
+ - - ">="
223
+ - !ruby/object:Gem::Version
224
+ version: 1.0.0
225
+ - !ruby/object:Gem::Dependency
226
+ name: simplecov
227
+ requirement: !ruby/object:Gem::Requirement
228
+ requirements:
229
+ - - "~>"
230
+ - !ruby/object:Gem::Version
231
+ version: 0.12.0
232
+ type: :development
233
+ prerelease: false
234
+ version_requirements: !ruby/object:Gem::Requirement
235
+ requirements:
236
+ - - "~>"
237
+ - !ruby/object:Gem::Version
238
+ version: 0.12.0
239
+ description: Ruby library to find ORCID IDs in the DataCite Solr index.
240
+ email: mfenner@datacite.org
241
+ executables:
242
+ - toccatore
243
+ extensions: []
244
+ extra_rdoc_files:
245
+ - README.md
246
+ files:
247
+ - ".gitignore"
248
+ - ".travis.yml"
249
+ - CHANGELOG.md
250
+ - Gemfile
251
+ - Gemfile.lock
252
+ - LICENSE.md
253
+ - README.md
254
+ - bin/toccatore
255
+ - lib/toccatore.rb
256
+ - lib/toccatore/base.rb
257
+ - lib/toccatore/cli.rb
258
+ - lib/toccatore/orcid_update.rb
259
+ - lib/toccatore/version.rb
260
+ - spec/cli_spec.rb
261
+ - spec/fixtures/orcid_update.json
262
+ - spec/fixtures/orcid_update_nil.json
263
+ - spec/fixtures/vcr_cassettes/Toccatore_CLI/orcid_update/should_fail.yml
264
+ - spec/fixtures/vcr_cassettes/Toccatore_CLI/orcid_update/should_succeed.yml
265
+ - spec/fixtures/vcr_cassettes/Toccatore_OrcidUpdate/get_data/should_report_if_there_are_no_works_returned_by_the_Datacite_Metadata_Search_API.yml
266
+ - spec/fixtures/vcr_cassettes/Toccatore_OrcidUpdate/get_data/should_report_if_there_are_works_returned_by_the_Datacite_Metadata_Search_API.yml
267
+ - spec/fixtures/vcr_cassettes/Toccatore_OrcidUpdate/get_total/with_no_works.yml
268
+ - spec/fixtures/vcr_cassettes/Toccatore_OrcidUpdate/get_total/with_works.yml
269
+ - spec/fixtures/vcr_cassettes/Toccatore_OrcidUpdate/push_data/should_report_if_there_are_works_returned_by_the_Datacite_Metadata_Search_API.yml
270
+ - spec/fixtures/vcr_cassettes/Toccatore_OrcidUpdate/queue_jobs/should_report_if_there_are_no_works_returned_by_the_Datacite_Metadata_Search_API.yml
271
+ - spec/fixtures/vcr_cassettes/Toccatore_OrcidUpdate/queue_jobs/should_report_if_there_are_works_returned_by_the_Datacite_Metadata_Search_API.yml
272
+ - spec/orcid_update_spec.rb
273
+ - spec/spec_helper.rb
274
+ - toccatore.gemspec
275
+ homepage: https://github.com/datacite/toccatore
276
+ licenses:
277
+ - MIT
278
+ metadata: {}
279
+ post_install_message:
280
+ rdoc_options: []
281
+ require_paths:
282
+ - lib
283
+ required_ruby_version: !ruby/object:Gem::Requirement
284
+ requirements:
285
+ - - ">="
286
+ - !ruby/object:Gem::Version
287
+ version: '0'
288
+ required_rubygems_version: !ruby/object:Gem::Requirement
289
+ requirements:
290
+ - - ">="
291
+ - !ruby/object:Gem::Version
292
+ version: '0'
293
+ requirements: []
294
+ rubyforge_project:
295
+ rubygems_version: 2.6.8
296
+ signing_key:
297
+ specification_version: 4
298
+ summary: Ruby library to find ORCID IDs in the DataCite Solr index
299
+ test_files:
300
+ - spec/cli_spec.rb
301
+ - spec/fixtures/orcid_update.json
302
+ - spec/fixtures/orcid_update_nil.json
303
+ - spec/fixtures/vcr_cassettes/Toccatore_CLI/orcid_update/should_fail.yml
304
+ - spec/fixtures/vcr_cassettes/Toccatore_CLI/orcid_update/should_succeed.yml
305
+ - spec/fixtures/vcr_cassettes/Toccatore_OrcidUpdate/get_data/should_report_if_there_are_no_works_returned_by_the_Datacite_Metadata_Search_API.yml
306
+ - spec/fixtures/vcr_cassettes/Toccatore_OrcidUpdate/get_data/should_report_if_there_are_works_returned_by_the_Datacite_Metadata_Search_API.yml
307
+ - spec/fixtures/vcr_cassettes/Toccatore_OrcidUpdate/get_total/with_no_works.yml
308
+ - spec/fixtures/vcr_cassettes/Toccatore_OrcidUpdate/get_total/with_works.yml
309
+ - spec/fixtures/vcr_cassettes/Toccatore_OrcidUpdate/push_data/should_report_if_there_are_works_returned_by_the_Datacite_Metadata_Search_API.yml
310
+ - spec/fixtures/vcr_cassettes/Toccatore_OrcidUpdate/queue_jobs/should_report_if_there_are_no_works_returned_by_the_Datacite_Metadata_Search_API.yml
311
+ - spec/fixtures/vcr_cassettes/Toccatore_OrcidUpdate/queue_jobs/should_report_if_there_are_works_returned_by_the_Datacite_Metadata_Search_API.yml
312
+ - spec/orcid_update_spec.rb
313
+ - spec/spec_helper.rb
314
+ has_rdoc: