serrano 1.0.0 → 1.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 75729f32a4cfabb79a33d78638a91c253fb76a8ec3abc8d9ecc743056464d38d
4
- data.tar.gz: 8e47227794125651a8c35450a8f7f5aaa5c377ac461ea2433836d00b76fdb699
3
+ metadata.gz: 4cfcf7f23380a97af986d90644b8ab541f89c14e5df46485ad84fbcff437a361
4
+ data.tar.gz: ff3571fbbe79b62cb203e54887c09a0f5af81838a7e0e7aec8c2cb3fa1376890
5
5
  SHA512:
6
- metadata.gz: a1be1549ce95a4fa7bac8d417f28f9c2d70e800b48f1f7b8c4471cf8461ca37288dd9a2f06c5c15376364e3af4f8d4e61589ad0b4e0f8cdbbd6c1bf46fc170db
7
- data.tar.gz: d21603574250c471ea20c3fe7f433d5ef56715307442d8067814757b522306afdca717bbcd612eda4055c1e1b41fc2a8a3f9d340d45dd57127c9a3950b24f70a
6
+ metadata.gz: 057e9ff07332d37fcd6711695ddd2648d7fd76f74a87585c795a9412883ee4346cf0868b5819f6025e8fee3ef687ac1da035f8ecbfb07424450f5a161daa88a2
7
+ data.tar.gz: a47b838e2812df16d600df5530175d31682679e2070e78ad0c8c6250f6b65c1e67d71d6a9cc31fefc055caa59de40148f842ec607b68264845eca55ab1a9cfab
@@ -0,0 +1,22 @@
1
+ version: 2
2
+ updates:
3
+ - package-ecosystem: bundler
4
+ directory: "/"
5
+ schedule:
6
+ interval: daily
7
+ time: "13:00"
8
+ open-pull-requests-limit: 10
9
+ ignore:
10
+ - dependency-name: codecov
11
+ versions:
12
+ - "> 0.1.17, < 0.2"
13
+ - dependency-name: codecov
14
+ versions:
15
+ - "> 0.2.1, < 0.3"
16
+ - dependency-name: codecov
17
+ versions:
18
+ - 0.4.2
19
+ - 0.4.3
20
+ - dependency-name: simplecov
21
+ versions:
22
+ - 0.20.0
@@ -2,17 +2,17 @@ name: Ruby
2
2
 
3
3
  on:
4
4
  push:
5
- branches: [ master ]
5
+ branches: [ main ]
6
6
  pull_request:
7
- branches: [ master ]
7
+ branches: [ main ]
8
8
 
9
9
  jobs:
10
10
  test:
11
11
  strategy:
12
12
  fail-fast: false
13
13
  matrix:
14
- os: [ ubuntu-latest, macos-latest ]
15
- ruby: [ 2.5, 2.6, 2.7 ]
14
+ os: [ ubuntu-latest, macos-11 ]
15
+ ruby: [ 2.6, 2.7, 3.0, 3.1 ]
16
16
  runs-on: ${{ matrix.os }}
17
17
  env:
18
18
  CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
data/CHANGELOG.md CHANGED
@@ -1,3 +1,9 @@
1
+ ## 1.4 (2022-03-26)
2
+
3
+ * Moved to faraday > v2. There's no user facing changes here, but let me know if any issues arise (#172)
4
+ * PR by @LocoDelAssembly fixes `Serrano.content_negotiation(format: "citeproc-json")` by having it return `nil` instead of `Resource not found` when no DOI is found, so that the output is more compatible with flows that use serrano to create JSON (#169)
5
+ * PR by @xuanxu adds `REXML` as a runtime dependency (#159)
6
+
1
7
  ## 1.0.0 (2020-10-19)
2
8
 
3
9
  * updated dependency versions
data/LICENSE CHANGED
@@ -1,4 +1,4 @@
1
- Copyright (C) 2020 Scott Chamberlain
1
+ Copyright (C) 2022 Scott Chamberlain
2
2
 
3
3
  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
4
4
 
data/README.md CHANGED
@@ -3,7 +3,7 @@ serrano
3
3
 
4
4
  [![gem version](https://img.shields.io/gem/v/serrano.svg)](https://rubygems.org/gems/serrano)
5
5
  [![Ruby](https://github.com/sckott/serrano/workflows/Ruby/badge.svg)](https://github.com/sckott/serrano/actions)
6
- [![codecov.io](https://codecov.io/github/sckott/serrano/coverage.svg?branch=master)](https://codecov.io/github/sckott/serrano?branch=master)
6
+ [![codecov.io](https://codecov.io/github/sckott/serrano/coverage.svg?branch=main)](https://codecov.io/github/sckott/serrano?branch=main)
7
7
  [![DOI](https://zenodo.org/badge/2600/sckott/serrano.svg)](https://zenodo.org/badge/latestdoi/2600/sckott/serrano)
8
8
  [![Ruby Style Guide](https://img.shields.io/badge/code_style-standard-brightgreen.svg)](https://github.com/testdouble/standard)
9
9
 
@@ -47,7 +47,7 @@ Other methods:
47
47
 
48
48
  Note about searching:
49
49
 
50
- You are using the Crossref search API described at https://github.com/CrossRef/rest-api-doc When you search with query terms, on Crossref servers they are not searching full text, or even abstracts of articles, but only what is available in the data that is returned to you. That is, they search article titles, authors, etc. For some discussion on this, see https://gitlab.com/crossref/issues/issues/101
50
+ You are using the Crossref search API described at https://api.crossref.org When you search with query terms, on Crossref servers they are not searching full text, or even abstracts of articles, but only what is available in the data that is returned to you. That is, they search article titles, authors, etc. For some discussion on this, see https://gitlab.com/crossref/issues/issues/101
51
51
 
52
52
  Rate limits:
53
53
 
@@ -184,6 +184,8 @@ Commands:
184
184
 
185
185
  # Many DOIs
186
186
  ~$ serrano works "10.1007/12080.1874-1746,10.1007/10452.1573-5125"
187
+ ## if above two dois in a file called dois.txt
188
+ ~$ cat dois.txt | xargs -I{} serrano works {}
187
189
 
188
190
  # output JSON, then parse with e.g., jq
189
191
  ~$ serrano works --filter=has_orcid:true --json --limit=2 | jq '.message.items[].author[].ORCID | select(. != null)'
@@ -194,9 +196,8 @@ Commands:
194
196
  * Please note that this project is released with a [Contributor Code of Conduct](CONDUCT.md). By participating in this project you agree to abide by its terms.
195
197
  * License: MIT
196
198
 
197
- [crapi]: https://github.com/CrossRef/rest-api-doc/blob/master/rest_api.md
199
+ [crapi]: https://api.crossref.org/
198
200
  [cn]: https://citation.crosscite.org/docs.html
199
- [tdm]: https://www.crossref.org/education/retrieve-metadata/rest-api/text-and-data-mining/
200
- [ccount]: https://labs.crossref.org/openurl/
201
+ [ccount]: https://www.crossref.org/documentation/retrieve-metadata/openurl/
201
202
  [csl]: https://github.com/citation-style-language/styles
202
- [changelog]: https://github.com/sckott/serrano/blob/master/CHANGELOG.md
203
+ [changelog]: https://github.com/sckott/serrano/blob/main/CHANGELOG.md
data/Rakefile CHANGED
@@ -44,3 +44,8 @@ desc "Release to Rubygems"
44
44
  task release: :build do
45
45
  system "gem push serrano-#{Serrano::VERSION}.gem"
46
46
  end
47
+
48
+ desc "open an irb session preloaded with this gem"
49
+ task :console do
50
+ sh "irb -r pp -r ./lib/serrano.rb"
51
+ end
@@ -1,7 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  require "faraday"
4
- require "faraday_middleware"
4
+ require "faraday/follow_redirects"
5
5
  require "multi_json"
6
6
  require "serrano/error"
7
7
  require "serrano/utils"
@@ -23,7 +23,7 @@ CN_FORMAT_HEADERS = {"rdf-xml" => "application/rdf+xml",
23
23
  #
24
24
  # Class to perform HTTP requests to the Crossref API
25
25
  module Serrano
26
- class CNRequest #:nodoc:
26
+ class CNRequest # :nodoc:
27
27
  attr_accessor :ids
28
28
  attr_accessor :format
29
29
  attr_accessor :style
@@ -47,12 +47,12 @@ module Serrano
47
47
  end
48
48
 
49
49
  conn = Faraday.new "https://doi.org/" do |c|
50
- c.use FaradayMiddleware::FollowRedirects
50
+ c.use Faraday::FollowRedirects::Middleware
51
51
  c.adapter :net_http
52
52
  end
53
53
 
54
54
  if ids.length == 1
55
- self.ids = ids[0] if ids.class == Array
55
+ self.ids = ids[0] if ids.instance_of?(Array)
56
56
  make_request(conn, ids, format, style, locale)
57
57
  else
58
58
  coll = []
@@ -87,19 +87,5 @@ def make_request(conn, ids, format, style, locale)
87
87
  }
88
88
  end
89
89
 
90
- res.body
90
+ res.body if res.success?
91
91
  end
92
-
93
- # parser <- cn_types[[self.format]]
94
- # if (raw) {
95
- # content(response, "text")
96
- # } else {
97
- # out <- content(response, "parsed", parser, "UTF-8")
98
- # if (format == "text") {
99
- # out <- gsub("\n", "", out)
100
- # }
101
- # if (format == "bibentry") {
102
- # out <- parse_bibtex(out)
103
- # }
104
- # out
105
- # }
@@ -4,69 +4,71 @@ require "faraday"
4
4
  require "multi_json"
5
5
 
6
6
  # @private
7
- module FaradayMiddleware
8
- # @private
9
- class RaiseHttpException < Faraday::Middleware
10
- def call(env)
11
- @app.call(env).on_complete do |response|
12
- case response[:status].to_i
13
- when 400
14
- raise Serrano::BadRequest, error_message_400(response)
15
- when 404
16
- raise Serrano::NotFound, error_message_400(response)
17
- when 500
18
- raise Serrano::InternalServerError, error_message_500(response, "Something is technically wrong.")
19
- when 502
20
- raise Serrano::BadGateway, error_message_500(response, "The server returned an invalid or incomplete response.")
21
- when 503
22
- raise Serrano::ServiceUnavailable, error_message_500(response, "Crossref is rate limiting your requests.")
23
- when 504
24
- raise Serrano::GatewayTimeout, error_message_500(response, "504 Gateway Time-out")
7
+ module Faraday
8
+ module SerranoErrors
9
+ # @private
10
+ class Middleware < Faraday::Middleware
11
+ def call(env)
12
+ @app.call(env).on_complete do |response|
13
+ case response[:status].to_i
14
+ when 400
15
+ raise Serrano::BadRequest, error_message_400(response)
16
+ when 404
17
+ raise Serrano::NotFound, error_message_400(response)
18
+ when 500
19
+ raise Serrano::InternalServerError, error_message_500(response, "Something is technically wrong.")
20
+ when 502
21
+ raise Serrano::BadGateway, error_message_500(response, "The server returned an invalid or incomplete response.")
22
+ when 503
23
+ raise Serrano::ServiceUnavailable, error_message_500(response, "Crossref is rate limiting your requests.")
24
+ when 504
25
+ raise Serrano::GatewayTimeout, error_message_500(response, "504 Gateway Time-out")
26
+ end
25
27
  end
26
28
  end
27
- end
28
29
 
29
- def initialize(app)
30
- super app
31
- @parser = nil
32
- end
30
+ def initialize(app)
31
+ super app
32
+ @parser = nil
33
+ end
33
34
 
34
- private
35
+ private
35
36
 
36
- def error_message_400(response)
37
- "\n #{response[:method].to_s.upcase} #{response[:url]}\n Status #{response[:status]}#{error_body(response[:body])}"
38
- end
37
+ def error_message_400(response)
38
+ "\n #{response[:method].to_s.upcase} #{response[:url]}\n Status #{response[:status]}#{error_body(response[:body])}"
39
+ end
39
40
 
40
- def error_body(body)
41
- if !body.nil? && !body.empty? && body.is_a?(String)
42
- if json?(body)
43
- body = ::MultiJson.load(body)
44
- if body["message"].nil?
45
- body = nil
46
- elseif body["message"].length == 1
47
- body = body["message"]
48
- else
49
- body = body["message"].collect { |x| x["message"] }.join("; ")
41
+ def error_body(body)
42
+ if !body.nil? && !body.empty? && body.is_a?(String)
43
+ if json?(body)
44
+ body = ::MultiJson.load(body)
45
+ if body["message"].nil?
46
+ body = nil
47
+ elseif body["message"].length == 1
48
+ body = body["message"]
49
+ else
50
+ body = body["message"].collect { |x| x["message"] }.join("; ")
51
+ end
50
52
  end
51
53
  end
52
- end
53
54
 
54
- if body.nil?
55
- nil
56
- else
57
- ": #{body}"
55
+ if body.nil?
56
+ nil
57
+ else
58
+ ": #{body}"
59
+ end
58
60
  end
59
- end
60
61
 
61
- def error_message_500(response, body = nil)
62
- "#{response[:method].to_s.upcase} #{response[:url]}: #{[response[:status].to_s + ":", body].compact.join(" ")}"
63
- end
62
+ def error_message_500(response, body = nil)
63
+ "#{response[:method].to_s.upcase} #{response[:url]}: #{[response[:status].to_s + ":", body].compact.join(" ")}"
64
+ end
64
65
 
65
- def json?(string)
66
- MultiJson.load(string)
67
- true
68
- rescue MultiJson::ParseError
69
- false
66
+ def json?(string)
67
+ MultiJson.load(string)
68
+ true
69
+ rescue MultiJson::ParseError
70
+ false
71
+ end
70
72
  end
71
73
  end
72
74
  end
@@ -52,11 +52,11 @@ module Helpers
52
52
  end
53
53
 
54
54
  module Serrano
55
- class Request #:nodoc:
55
+ class Request # :nodoc:
56
56
  include Helpers
57
57
  end
58
58
 
59
- class RequestCursor #:nodoc:
59
+ class RequestCursor # :nodoc:
60
60
  include Helpers
61
61
  end
62
62
  end
@@ -12,7 +12,7 @@ require "serrano/helpers/configuration"
12
12
  #
13
13
  # Class to perform HTTP requests to the Crossref API
14
14
  module Serrano
15
- class Request #:nodoc:
15
+ class Request # :nodoc:
16
16
  attr_accessor :endpt
17
17
  attr_accessor :id
18
18
  attr_accessor :query
@@ -53,24 +53,21 @@ module Serrano
53
53
  def perform
54
54
  filt = filter_handler(filter)
55
55
 
56
- self.select = select.join(",") if select && select.class == Array
56
+ self.select = select&.instance_of?(Array) ? select.join(",") : select
57
57
 
58
- args = {query: query, filter: filt, offset: offset,
59
- rows: limit, sample: sample, sort: sort,
60
- order: order, facet: facet,
58
+ args = {query: query, filter: filt, offset: offset, rows: limit,
59
+ sample: sample, sort: sort, order: order, facet: facet,
61
60
  select: select}
62
61
  opts = args.delete_if { |_k, v| v.nil? }
63
62
 
64
63
  conn = if verbose
65
- Faraday.new(url: Serrano.base_url, request: options || []) do |f|
64
+ Faraday.new(url: Serrano.base_url, request: options || {}) do |f|
66
65
  f.response :logger
67
- f.use FaradayMiddleware::RaiseHttpException
68
- f.adapter Faraday.default_adapter
66
+ f.use Faraday::SerranoErrors::Middleware
69
67
  end
70
68
  else
71
- Faraday.new(url: Serrano.base_url, request: options || []) do |f|
72
- f.use FaradayMiddleware::RaiseHttpException
73
- f.adapter Faraday.default_adapter
69
+ Faraday.new(url: Serrano.base_url, request: options || {}) do |f|
70
+ f.use Faraday::SerranoErrors::Middleware
74
71
  end
75
72
  end
76
73
 
@@ -2,12 +2,10 @@
2
2
 
3
3
  require "erb"
4
4
  require "faraday"
5
- require "faraday_middleware"
6
5
  require "multi_json"
7
6
  require "serrano/error"
8
7
  require "serrano/helpers/configuration"
9
8
  require "serrano/filterhandler"
10
- require "serrano/error"
11
9
  require "serrano/faraday"
12
10
  require "serrano/utils"
13
11
 
@@ -16,7 +14,7 @@ require "serrano/utils"
16
14
  #
17
15
  # Class to perform HTTP requests to the Crossref API
18
16
  module Serrano
19
- class RequestCursor #:nodoc:
17
+ class RequestCursor # :nodoc:
20
18
  attr_accessor :endpt
21
19
  attr_accessor :id
22
20
  attr_accessor :query
@@ -64,7 +62,7 @@ module Serrano
64
62
  def perform
65
63
  filt = filter_handler(filter)
66
64
  fieldqueries = field_query_handler(args)
67
- self.select = select.join(",") if select && select.class == Array
65
+ self.select = select&.instance_of?(Array) ? select.join(",") : select
68
66
 
69
67
  unless cursor_max.class.nil?
70
68
  raise "cursor_max must be of class int" unless cursor_max.is_a?(Integer)
@@ -78,15 +76,13 @@ module Serrano
78
76
  opts = arguments.delete_if { |_k, v| v.nil? }
79
77
 
80
78
  conn = if verbose
81
- Faraday.new(url: Serrano.base_url, request: options || []) do |f|
79
+ Faraday.new(url: Serrano.base_url, request: options || {}) do |f|
82
80
  f.response :logger
83
- f.use FaradayMiddleware::RaiseHttpException
84
- f.adapter Faraday.default_adapter
81
+ f.use Faraday::SerranoErrors::Middleware
85
82
  end
86
83
  else
87
- Faraday.new(url: Serrano.base_url, request: options || []) do |f|
88
- f.use FaradayMiddleware::RaiseHttpException
89
- f.adapter Faraday.default_adapter
84
+ Faraday.new(url: Serrano.base_url, request: options || {}) do |f|
85
+ f.use Faraday::SerranoErrors::Middleware
90
86
  end
91
87
  end
92
88
 
@@ -98,7 +94,7 @@ module Serrano
98
94
  js = _req(conn, endpt, opts)
99
95
  cu = js["message"]["next-cursor"]
100
96
  max_avail = js["message"]["total-results"]
101
- _redo_req(conn, js, opts, cu, max_avail)
97
+ _redo_req(conn, js, opts, cu, max_avail, endpt2)
102
98
 
103
99
  else
104
100
  self.id = Array(id)
@@ -119,13 +115,13 @@ module Serrano
119
115
  js = _req(conn, endpt2, opts)
120
116
  cu = js["message"]["next-cursor"]
121
117
  max_avail = js["message"]["total-results"]
122
- coll << _redo_req(conn, js, opts, cu, max_avail)
118
+ coll << _redo_req(conn, js, opts, cu, max_avail, endpt2)
123
119
  end
124
120
  coll
125
121
  end
126
122
  end
127
123
 
128
- def _redo_req(conn, js, opts, cu, max_avail)
124
+ def _redo_req(conn, js, opts, cu, max_avail, endpt2)
129
125
  if !cu.nil? && (cursor_max > js["message"]["items"].length)
130
126
  res = [js]
131
127
  total = js["message"]["items"].length
@@ -6,8 +6,8 @@ require "multi_json"
6
6
  def fetch_styles
7
7
  base = "https://api.github.com/repos/citation-style-language/styles"
8
8
  conn = Faraday.new(url: base) { |f|
9
- f.use FaradayMiddleware::RaiseHttpException
10
- f.adapter Faraday.default_adapter
9
+ f.use Faraday::Response::RaiseError
10
+ # f.adapter Faraday.default_adapter
11
11
  }
12
12
  args = {per_page: 1}
13
13
  tt = conn.get "commits", args
data/lib/serrano/utils.rb CHANGED
@@ -24,12 +24,12 @@ end
24
24
 
25
25
  class Hash
26
26
  def tostrings
27
- Hash[map { |(k, v)| [k.to_s, v] }]
27
+ map { |(k, v)| [k.to_s, v] }.to_h
28
28
  end
29
29
  end
30
30
 
31
31
  class Hash
32
32
  def tosymbols
33
- Hash[map { |(k, v)| [k.to_sym, v] }]
33
+ map { |(k, v)| [k.to_sym, v] }.to_h
34
34
  end
35
35
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Serrano
4
- VERSION = "1.0.0"
4
+ VERSION = "1.4"
5
5
  end
data/lib/serrano.rb CHANGED
@@ -42,8 +42,7 @@ require "rexml/xpath"
42
42
  # @param cursor [String] Cursor character string to do deep paging. Default is `nil`.
43
43
  # Pass in '*' to start deep paging. Any combination of query, filters and facets may be
44
44
  # used with deep paging cursors. While limit may be specified along with cursor, offset
45
- # and sample cannot be used. See
46
- # https://github.com/CrossRef/rest-api-doc/blob/master/rest_api.md#deep-paging-with-cursors
45
+ # and sample cannot be used. See https://api.crossref.org/
47
46
  # @param cursor_max [Fixnum] Max records to retrieve. Only used when cursor
48
47
  # param used. Because deep paging can result in continuous requests until all
49
48
  # are retrieved, use this parameter to set a maximum number of records. Of course,
@@ -63,8 +62,7 @@ require "rexml/xpath"
63
62
  # - oauth [Hash] A hash with OAuth details
64
63
 
65
64
  # @!macro field_queries
66
- # @param [Hash<Object>] args Field queries, as named parameters. See
67
- # https://github.com/CrossRef/rest-api-doc/blob/master/rest_api.md#field-queries
65
+ # @param [Hash<Object>] args Field queries, as named parameters. See https://api.crossref.org/
68
66
  # Field query parameters mut be named, and must start with `query_`. Any dashes or
69
67
  # periods should be replaced with underscores. The options include:
70
68
  # - query_container_title: Query container-title aka. publication name
@@ -99,18 +97,16 @@ require "rexml/xpath"
99
97
  # For example, if you want to inspect headers returned from the HTTP request,
100
98
  # and parse the raw result in any way you wish.
101
99
  #
102
- # @see https://github.com/CrossRef/rest-api-doc/blob/master/rest_api.md for
103
- # detailed description of the Crossref API
100
+ # @see https://api.crossref.org for detailed description of the Crossref API
104
101
  #
105
102
  # What am I actually searching when using the Crossref search API?
106
103
  #
107
- # You are using the Crossref search API described at
108
- # https://github.com/CrossRef/rest-api-doc/blob/master/rest_api.md.
104
+ # You are using the Crossref search API described at https://api.crossref.org
109
105
  # When you search with query terms, on Crossref servers they are not
110
106
  # searching full text, or even abstracts of articles, but only what is
111
107
  # available in the data that is returned to you. That is, they search
112
108
  # article titles, authors, etc. For some discussion on this, see
113
- # https://gitlab.com/crossref/issues/issues/101
109
+ # https://gitlab.com/crossref/issues/-/issues/101
114
110
  #
115
111
  #
116
112
  # The Polite Pool
@@ -643,7 +639,8 @@ module Serrano
643
639
  # @param url [String] the API url for the function (should be left to default)
644
640
  # @param key [String] your API key
645
641
  #
646
- # @see http://labs.crossref.org/openurl/ for more info on this Crossref API service.
642
+ # @see https://www.crossref.org/documentation/retrieve-metadata/openurl/ for
643
+ # more info on this Crossref API service.
647
644
  #
648
645
  # @example
649
646
  # require 'serrano'
data/serrano.gemspec CHANGED
@@ -9,7 +9,6 @@ Gem::Specification.new do |s|
9
9
  s.version = Serrano::VERSION
10
10
  s.platform = Gem::Platform::RUBY
11
11
  s.required_ruby_version = ">= 2.1"
12
- s.date = "2020-10-19"
13
12
  s.summary = "Crossref Client"
14
13
  s.description = "Low Level Ruby Client for the Crossref Search API"
15
14
  s.authors = "Scott Chamberlain"
@@ -25,20 +24,21 @@ Gem::Specification.new do |s|
25
24
  s.bindir = "bin"
26
25
  s.executables = ["serrano"]
27
26
 
28
- s.add_development_dependency "bundler", '~> 2.1', '>= 2.1.4'
29
- s.add_development_dependency "codecov", "~> 0.2.0"
30
- s.add_development_dependency "json", '~> 2.3', '>= 2.3.1'
31
- s.add_development_dependency "rake", '~> 13.0', '>= 13.0.1'
32
- s.add_development_dependency "standard", "~> 0.7"
33
- s.add_development_dependency "simplecov", "~> 0.19.0"
34
- s.add_development_dependency "test-unit", '~> 3.3', '>= 3.3.6'
35
- s.add_development_dependency "vcr", "~> 6.0"
36
- s.add_development_dependency "webmock", '~> 3.9', '>= 3.9.3'
27
+ s.add_development_dependency "bundler", "~> 2.1", ">= 2.1.4"
28
+ s.add_development_dependency "codecov", "~> 0.5.0"
29
+ s.add_development_dependency "json", "~> 2.3", ">= 2.3.1"
30
+ s.add_development_dependency "rake", "~> 13.0", ">= 13.0.1"
31
+ s.add_development_dependency "standard", "~> 1.0"
32
+ s.add_development_dependency "simplecov", "~> 0.21.2"
33
+ s.add_development_dependency "test-unit", "~> 3.3", ">= 3.3.6"
34
+ s.add_development_dependency "vcr", "~> 6.1"
35
+ s.add_development_dependency "webmock", "~> 3.14"
37
36
 
38
- s.add_runtime_dependency "faraday", "~> 1.1"
39
- s.add_runtime_dependency "faraday_middleware", "~> 1.0"
40
- s.add_runtime_dependency "multi_json", '~> 1.15'
41
- s.add_runtime_dependency 'thor', '~> 1.0', '>= 1.0.1'
37
+ s.add_runtime_dependency "faraday", "~> 2.2"
38
+ s.add_runtime_dependency "faraday-follow_redirects", "~> 0.1.0"
39
+ s.add_runtime_dependency "multi_json", "~> 1.15"
40
+ s.add_runtime_dependency "rexml", "~> 3.2", ">= 3.2.5"
41
+ s.add_runtime_dependency "thor", "~> 1.2", ">= 1.2.1"
42
42
 
43
43
  s.metadata = {
44
44
  "homepage_uri" => "https://github.com/sckott/serrano",
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: serrano
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: '1.4'
5
5
  platform: ruby
6
6
  authors:
7
7
  - Scott Chamberlain
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-10-19 00:00:00.000000000 Z
11
+ date: 2022-03-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -36,14 +36,14 @@ dependencies:
36
36
  requirements:
37
37
  - - "~>"
38
38
  - !ruby/object:Gem::Version
39
- version: 0.2.0
39
+ version: 0.5.0
40
40
  type: :development
41
41
  prerelease: false
42
42
  version_requirements: !ruby/object:Gem::Requirement
43
43
  requirements:
44
44
  - - "~>"
45
45
  - !ruby/object:Gem::Version
46
- version: 0.2.0
46
+ version: 0.5.0
47
47
  - !ruby/object:Gem::Dependency
48
48
  name: json
49
49
  requirement: !ruby/object:Gem::Requirement
@@ -90,28 +90,28 @@ dependencies:
90
90
  requirements:
91
91
  - - "~>"
92
92
  - !ruby/object:Gem::Version
93
- version: '0.7'
93
+ version: '1.0'
94
94
  type: :development
95
95
  prerelease: false
96
96
  version_requirements: !ruby/object:Gem::Requirement
97
97
  requirements:
98
98
  - - "~>"
99
99
  - !ruby/object:Gem::Version
100
- version: '0.7'
100
+ version: '1.0'
101
101
  - !ruby/object:Gem::Dependency
102
102
  name: simplecov
103
103
  requirement: !ruby/object:Gem::Requirement
104
104
  requirements:
105
105
  - - "~>"
106
106
  - !ruby/object:Gem::Version
107
- version: 0.19.0
107
+ version: 0.21.2
108
108
  type: :development
109
109
  prerelease: false
110
110
  version_requirements: !ruby/object:Gem::Requirement
111
111
  requirements:
112
112
  - - "~>"
113
113
  - !ruby/object:Gem::Version
114
- version: 0.19.0
114
+ version: 0.21.2
115
115
  - !ruby/object:Gem::Dependency
116
116
  name: test-unit
117
117
  requirement: !ruby/object:Gem::Requirement
@@ -138,62 +138,56 @@ dependencies:
138
138
  requirements:
139
139
  - - "~>"
140
140
  - !ruby/object:Gem::Version
141
- version: '6.0'
141
+ version: '6.1'
142
142
  type: :development
143
143
  prerelease: false
144
144
  version_requirements: !ruby/object:Gem::Requirement
145
145
  requirements:
146
146
  - - "~>"
147
147
  - !ruby/object:Gem::Version
148
- version: '6.0'
148
+ version: '6.1'
149
149
  - !ruby/object:Gem::Dependency
150
150
  name: webmock
151
151
  requirement: !ruby/object:Gem::Requirement
152
152
  requirements:
153
153
  - - "~>"
154
154
  - !ruby/object:Gem::Version
155
- version: '3.9'
156
- - - ">="
157
- - !ruby/object:Gem::Version
158
- version: 3.9.3
155
+ version: '3.14'
159
156
  type: :development
160
157
  prerelease: false
161
158
  version_requirements: !ruby/object:Gem::Requirement
162
159
  requirements:
163
160
  - - "~>"
164
161
  - !ruby/object:Gem::Version
165
- version: '3.9'
166
- - - ">="
167
- - !ruby/object:Gem::Version
168
- version: 3.9.3
162
+ version: '3.14'
169
163
  - !ruby/object:Gem::Dependency
170
164
  name: faraday
171
165
  requirement: !ruby/object:Gem::Requirement
172
166
  requirements:
173
167
  - - "~>"
174
168
  - !ruby/object:Gem::Version
175
- version: '1.1'
169
+ version: '2.2'
176
170
  type: :runtime
177
171
  prerelease: false
178
172
  version_requirements: !ruby/object:Gem::Requirement
179
173
  requirements:
180
174
  - - "~>"
181
175
  - !ruby/object:Gem::Version
182
- version: '1.1'
176
+ version: '2.2'
183
177
  - !ruby/object:Gem::Dependency
184
- name: faraday_middleware
178
+ name: faraday-follow_redirects
185
179
  requirement: !ruby/object:Gem::Requirement
186
180
  requirements:
187
181
  - - "~>"
188
182
  - !ruby/object:Gem::Version
189
- version: '1.0'
183
+ version: 0.1.0
190
184
  type: :runtime
191
185
  prerelease: false
192
186
  version_requirements: !ruby/object:Gem::Requirement
193
187
  requirements:
194
188
  - - "~>"
195
189
  - !ruby/object:Gem::Version
196
- version: '1.0'
190
+ version: 0.1.0
197
191
  - !ruby/object:Gem::Dependency
198
192
  name: multi_json
199
193
  requirement: !ruby/object:Gem::Requirement
@@ -208,26 +202,46 @@ dependencies:
208
202
  - - "~>"
209
203
  - !ruby/object:Gem::Version
210
204
  version: '1.15'
205
+ - !ruby/object:Gem::Dependency
206
+ name: rexml
207
+ requirement: !ruby/object:Gem::Requirement
208
+ requirements:
209
+ - - "~>"
210
+ - !ruby/object:Gem::Version
211
+ version: '3.2'
212
+ - - ">="
213
+ - !ruby/object:Gem::Version
214
+ version: 3.2.5
215
+ type: :runtime
216
+ prerelease: false
217
+ version_requirements: !ruby/object:Gem::Requirement
218
+ requirements:
219
+ - - "~>"
220
+ - !ruby/object:Gem::Version
221
+ version: '3.2'
222
+ - - ">="
223
+ - !ruby/object:Gem::Version
224
+ version: 3.2.5
211
225
  - !ruby/object:Gem::Dependency
212
226
  name: thor
213
227
  requirement: !ruby/object:Gem::Requirement
214
228
  requirements:
215
229
  - - "~>"
216
230
  - !ruby/object:Gem::Version
217
- version: '1.0'
231
+ version: '1.2'
218
232
  - - ">="
219
233
  - !ruby/object:Gem::Version
220
- version: 1.0.1
234
+ version: 1.2.1
221
235
  type: :runtime
222
236
  prerelease: false
223
237
  version_requirements: !ruby/object:Gem::Requirement
224
238
  requirements:
225
239
  - - "~>"
226
240
  - !ruby/object:Gem::Version
227
- version: '1.0'
241
+ version: '1.2'
228
242
  - - ">="
229
243
  - !ruby/object:Gem::Version
230
- version: 1.0.1
244
+ version: 1.2.1
231
245
  description: Low Level Ruby Client for the Crossref Search API
232
246
  email: myrmecocystus@gmail.com
233
247
  executables:
@@ -235,6 +249,7 @@ executables:
235
249
  extensions: []
236
250
  extra_rdoc_files: []
237
251
  files:
252
+ - ".github/dependabot.yml"
238
253
  - ".github/workflows/ruby.yml"
239
254
  - ".gitignore"
240
255
  - CHANGELOG.md
@@ -264,10 +279,10 @@ licenses:
264
279
  metadata:
265
280
  homepage_uri: https://github.com/sckott/serrano
266
281
  documentation_uri: https://www.rubydoc.info/gems/serrano
267
- changelog_uri: https://github.com/sckott/serrano/releases/tag/v1.0.0
282
+ changelog_uri: https://github.com/sckott/serrano/releases/tag/v1.4
268
283
  source_code_uri: https://github.com/sckott/serrano
269
284
  bug_tracker_uri: https://github.com/sckott/serrano/issues
270
- post_install_message:
285
+ post_install_message:
271
286
  rdoc_options: []
272
287
  require_paths:
273
288
  - lib
@@ -282,8 +297,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
282
297
  - !ruby/object:Gem::Version
283
298
  version: '0'
284
299
  requirements: []
285
- rubygems_version: 3.1.2
286
- signing_key:
300
+ rubygems_version: 3.3.3
301
+ signing_key:
287
302
  specification_version: 4
288
303
  summary: Crossref Client
289
304
  test_files: []