curlyrest 0.1.38 → 0.1.40

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: 012b3dd1e5ca6122deb419d4772b168800186187b152389f9ebea030e1fa5438
4
- data.tar.gz: dc38fea01e185d90f448da812a0942064b349b2c7ffb7f9e05c06e641829e0d0
3
+ metadata.gz: 4c8d68729c4f31ab5b711b856b9bad72b362898fd1f68a513822304bbc99425c
4
+ data.tar.gz: 195c80010394c9250f023a592e6dbd36d0a4738b87093c3bb6f35cd23abb45bf
5
5
  SHA512:
6
- metadata.gz: '08626586bb774584dfa5086789624b5c2d70fe1da9291ebcf111fef59974a65ae897befda9508b88e277c1b3bb3c9ade257c31c6b9d4f91458d4caff54475029'
7
- data.tar.gz: e65db9e754650795ee82a300a843181462a270bdbe18cb080e1d3b7cec300b1462e8350a9c164e2822f917e9569283a561b972f24142fb3b6ac8be70b0934368
6
+ metadata.gz: '097f91b4f2d5733ec0cd1ba2e53e225e1ec8b8757cee69e957ee1cce3736132bb72e06692f8463f747bf60f93876d226f83940e3305fd30bae66cb00a9a39b6c'
7
+ data.tar.gz: a42517c1ab6c4949bdfa7cfa0cf491271ffb4e10d91bcf4a3fa2095704b7caa6bf9f0003ca0cd30f88431f81c1856da57c5c3d4ede5cc3d36ede5e7124798dad
data/README.md CHANGED
@@ -20,12 +20,12 @@ Or install it yourself as:
20
20
 
21
21
  ## Usage
22
22
 
23
- Simply replace your use of require 'rest-client' with require 'curlyrest', and optionally add header of :use_curl with true or 'debug' which will cause the request to be executed with curl and response parsed to be compatable with rest-client.
24
- Environment variable `FORCE_CURL_DEBUG` will cause all API calls to be executed and debugged with curl.
23
+ Simply replace your use of require 'rest-client' with require 'curlyrest', and optionally add header of :use_curl with either 'debug' (which will output the curl request / response) or any other value (which will execute via curl, but not output). The curl executed response is returned as compatable with rest-client.
24
+ Environment variable `FORCE_CURL_DEBUG` will cause all API calls to be executed and output with curl.
25
25
 
26
26
  ## Development
27
27
 
28
- To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
28
+ To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `lib/curlyrest/version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
29
29
 
30
30
  ## Limitations
31
31
 
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Curlyrest
4
- VERSION = '0.1.38'
4
+ VERSION = '0.1.40'
5
5
  end
data/lib/curlyrest.rb CHANGED
@@ -166,6 +166,7 @@ module RestClient
166
166
  if processed_headers['Use-Curl'] || ENV['FORCE_CURL_DEBUG']
167
167
  curl_execute(& block)
168
168
  else
169
+ @read_timeout = processed_headers['Timeout'].to_i if processed_headers['Timeout']
169
170
  transmit(uri, net_http_request_class(method)
170
171
  .new(uri, processed_headers),
171
172
  payload, & block)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: curlyrest
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.38
4
+ version: 0.1.40
5
5
  platform: ruby
6
6
  authors:
7
7
  - Keith Williams
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-09-17 00:00:00.000000000 Z
11
+ date: 2022-12-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: byebug