vultr 2.0.0 → 2.1.1

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,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9f3fe8cbbffe7e477b77e8ac4fa7d2210193c143847b9ec3587e8fb5e3822323
4
- data.tar.gz: 7d7f8e763854640c54ff1ed065c1e490a08b16aa3b5729689af2f3d9c33f2084
3
+ metadata.gz: 3f1110804534cc487ba3c66ad1f2ed8013ffb1b12994b15445a2e237ff540e31
4
+ data.tar.gz: 4b8026fb46e08aceb03c23c31aa260d02e48bfd9d310f4d50a1e23925d88f800
5
5
  SHA512:
6
- metadata.gz: 750d7e267c9b4c113a9a265acdebca5049d9a5fa89f2574de0a87d456987ff408deb0ad00e7e7141f1a47e745a56b2104f25fef08e8030823b75a356a2f84556
7
- data.tar.gz: 73795f5b4902a566f1b2f8875b8bd4d375727c0b5d3e0a35d66dbae73151b07b8ab70331a3349447446c4d8ed6dab78ef8c1d4715e22aafb5e2df36957476801
6
+ metadata.gz: 2d51536ea55723ad723489a9fe7233965ce3cec2a7ab4a87965dbb543d8e773a1f07f02202facf9677e0d138be122fec66c07840bc265d5dff05e3d7f3d42712
7
+ data.tar.gz: 4a626dc2f6626719c66b4bfff575b99eb826a2c969b23f2f92501d83f78bf640f706100aa77dce0eeff9ae213406653a98fd5661845883e54d361473b32ba4e2
@@ -12,7 +12,7 @@ jobs:
12
12
  runs-on: ubuntu-latest
13
13
  strategy:
14
14
  matrix:
15
- ruby: ["3.0", "3.1", "3.2", "3.3"]
15
+ ruby: ["3.0", "3.1", "3.2", "3.3", "3.4"]
16
16
  gemfile: ["faraday_1", "faraday_2"]
17
17
 
18
18
  env:
data/.standard.yml CHANGED
@@ -1 +1 @@
1
- ruby_version: 2.7
1
+ ruby_version: 3.0
data/CHANGELOG.md CHANGED
@@ -1,3 +1,11 @@
1
+ == 2.1.1 / 2025-5-21
2
+
3
+ * Improve `each` on Collection
4
+
5
+ == 2.1.0 / 2025-5-21
6
+
7
+ * Add enumerable to Collection
8
+
1
9
  == 2.0.0 / 2024-5-31
2
10
 
3
11
  * Drop Ruby 2.7 and older support
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: ..
3
3
  specs:
4
- vultr (2.0.0)
4
+ vultr (2.1.1)
5
5
  faraday (>= 1.0, < 3.0)
6
6
 
7
7
  GEM
@@ -11,9 +11,9 @@ GEM
11
11
  bundler
12
12
  rake
13
13
  thor (>= 0.14.0)
14
- ast (2.4.2)
14
+ ast (2.4.3)
15
15
  base64 (0.2.0)
16
- faraday (1.10.3)
16
+ faraday (1.10.4)
17
17
  faraday-em_http (~> 1.0)
18
18
  faraday-em_synchrony (~> 1.0)
19
19
  faraday-excon (~> 1.1)
@@ -29,61 +29,63 @@ GEM
29
29
  faraday-em_synchrony (1.0.0)
30
30
  faraday-excon (1.1.0)
31
31
  faraday-httpclient (1.0.1)
32
- faraday-multipart (1.0.4)
33
- multipart-post (~> 2)
34
- faraday-net_http (1.0.1)
32
+ faraday-multipart (1.1.0)
33
+ multipart-post (~> 2.0)
34
+ faraday-net_http (1.0.2)
35
35
  faraday-net_http_persistent (1.2.0)
36
36
  faraday-patron (1.0.0)
37
37
  faraday-rack (1.0.0)
38
38
  faraday-retry (1.0.3)
39
- json (2.7.2)
40
- language_server-protocol (3.17.0.3)
39
+ json (2.12.0)
40
+ language_server-protocol (3.17.0.5)
41
41
  lint_roller (1.1.0)
42
- minitest (5.23.1)
42
+ minitest (5.25.5)
43
43
  multipart-post (2.4.1)
44
- parallel (1.24.0)
45
- parser (3.3.2.0)
44
+ parallel (1.27.0)
45
+ parser (3.3.8.0)
46
46
  ast (~> 2.4.1)
47
47
  racc
48
- racc (1.8.0)
48
+ prism (1.4.0)
49
+ racc (1.8.1)
49
50
  rainbow (3.1.1)
50
51
  rake (13.2.1)
51
- regexp_parser (2.9.2)
52
- rexml (3.2.8)
53
- strscan (>= 3.0.9)
54
- rubocop (1.63.5)
52
+ regexp_parser (2.10.0)
53
+ rubocop (1.75.6)
55
54
  json (~> 2.3)
56
- language_server-protocol (>= 3.17.0)
55
+ language_server-protocol (~> 3.17.0.2)
56
+ lint_roller (~> 1.1.0)
57
57
  parallel (~> 1.10)
58
58
  parser (>= 3.3.0.2)
59
59
  rainbow (>= 2.2.2, < 4.0)
60
- regexp_parser (>= 1.8, < 3.0)
61
- rexml (>= 3.2.5, < 4.0)
62
- rubocop-ast (>= 1.31.1, < 2.0)
60
+ regexp_parser (>= 2.9.3, < 3.0)
61
+ rubocop-ast (>= 1.44.0, < 2.0)
63
62
  ruby-progressbar (~> 1.7)
64
- unicode-display_width (>= 2.4.0, < 3.0)
65
- rubocop-ast (1.31.3)
66
- parser (>= 3.3.1.0)
67
- rubocop-performance (1.21.0)
68
- rubocop (>= 1.48.1, < 2.0)
69
- rubocop-ast (>= 1.31.1, < 2.0)
63
+ unicode-display_width (>= 2.4.0, < 4.0)
64
+ rubocop-ast (1.44.1)
65
+ parser (>= 3.3.7.2)
66
+ prism (~> 1.4)
67
+ rubocop-performance (1.25.0)
68
+ lint_roller (~> 1.1)
69
+ rubocop (>= 1.75.0, < 2.0)
70
+ rubocop-ast (>= 1.38.0, < 2.0)
70
71
  ruby-progressbar (1.13.0)
71
72
  ruby2_keywords (0.0.5)
72
- standard (1.36.0)
73
+ standard (1.50.0)
73
74
  language_server-protocol (~> 3.17.0.2)
74
75
  lint_roller (~> 1.0)
75
- rubocop (~> 1.63.0)
76
+ rubocop (~> 1.75.5)
76
77
  standard-custom (~> 1.0.0)
77
- standard-performance (~> 1.4)
78
+ standard-performance (~> 1.8)
78
79
  standard-custom (1.0.2)
79
80
  lint_roller (~> 1.0)
80
81
  rubocop (~> 1.50)
81
- standard-performance (1.4.0)
82
+ standard-performance (1.8.0)
82
83
  lint_roller (~> 1.1)
83
- rubocop-performance (~> 1.21.0)
84
- strscan (3.1.0)
85
- thor (1.3.1)
86
- unicode-display_width (2.5.0)
84
+ rubocop-performance (~> 1.25.0)
85
+ thor (1.3.2)
86
+ unicode-display_width (3.1.4)
87
+ unicode-emoji (~> 4.0, >= 4.0.4)
88
+ unicode-emoji (4.0.4)
87
89
 
88
90
  PLATFORMS
89
91
  ruby
@@ -99,4 +101,4 @@ DEPENDENCIES
99
101
  vultr!
100
102
 
101
103
  BUNDLED WITH
102
- 2.5.10
104
+ 2.6.9
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: ..
3
3
  specs:
4
- vultr (2.0.0)
4
+ vultr (2.1.1)
5
5
  faraday (>= 1.0, < 3.0)
6
6
 
7
7
  GEM
@@ -11,60 +11,65 @@ GEM
11
11
  bundler
12
12
  rake
13
13
  thor (>= 0.14.0)
14
- ast (2.4.2)
15
- faraday (2.9.0)
16
- faraday-net_http (>= 2.0, < 3.2)
17
- faraday-net_http (3.1.0)
18
- net-http
19
- json (2.7.2)
20
- language_server-protocol (3.17.0.3)
14
+ ast (2.4.3)
15
+ faraday (2.13.1)
16
+ faraday-net_http (>= 2.0, < 3.5)
17
+ json
18
+ logger
19
+ faraday-net_http (3.4.0)
20
+ net-http (>= 0.5.0)
21
+ json (2.12.0)
22
+ language_server-protocol (3.17.0.5)
21
23
  lint_roller (1.1.0)
22
- minitest (5.23.1)
23
- net-http (0.4.1)
24
+ logger (1.7.0)
25
+ minitest (5.25.5)
26
+ net-http (0.6.0)
24
27
  uri
25
- parallel (1.24.0)
26
- parser (3.3.2.0)
28
+ parallel (1.27.0)
29
+ parser (3.3.8.0)
27
30
  ast (~> 2.4.1)
28
31
  racc
29
- racc (1.8.0)
32
+ prism (1.4.0)
33
+ racc (1.8.1)
30
34
  rainbow (3.1.1)
31
35
  rake (13.2.1)
32
- regexp_parser (2.9.2)
33
- rexml (3.2.8)
34
- strscan (>= 3.0.9)
35
- rubocop (1.63.5)
36
+ regexp_parser (2.10.0)
37
+ rubocop (1.75.6)
36
38
  json (~> 2.3)
37
- language_server-protocol (>= 3.17.0)
39
+ language_server-protocol (~> 3.17.0.2)
40
+ lint_roller (~> 1.1.0)
38
41
  parallel (~> 1.10)
39
42
  parser (>= 3.3.0.2)
40
43
  rainbow (>= 2.2.2, < 4.0)
41
- regexp_parser (>= 1.8, < 3.0)
42
- rexml (>= 3.2.5, < 4.0)
43
- rubocop-ast (>= 1.31.1, < 2.0)
44
+ regexp_parser (>= 2.9.3, < 3.0)
45
+ rubocop-ast (>= 1.44.0, < 2.0)
44
46
  ruby-progressbar (~> 1.7)
45
- unicode-display_width (>= 2.4.0, < 3.0)
46
- rubocop-ast (1.31.3)
47
- parser (>= 3.3.1.0)
48
- rubocop-performance (1.21.0)
49
- rubocop (>= 1.48.1, < 2.0)
50
- rubocop-ast (>= 1.31.1, < 2.0)
47
+ unicode-display_width (>= 2.4.0, < 4.0)
48
+ rubocop-ast (1.44.1)
49
+ parser (>= 3.3.7.2)
50
+ prism (~> 1.4)
51
+ rubocop-performance (1.25.0)
52
+ lint_roller (~> 1.1)
53
+ rubocop (>= 1.75.0, < 2.0)
54
+ rubocop-ast (>= 1.38.0, < 2.0)
51
55
  ruby-progressbar (1.13.0)
52
- standard (1.36.0)
56
+ standard (1.50.0)
53
57
  language_server-protocol (~> 3.17.0.2)
54
58
  lint_roller (~> 1.0)
55
- rubocop (~> 1.63.0)
59
+ rubocop (~> 1.75.5)
56
60
  standard-custom (~> 1.0.0)
57
- standard-performance (~> 1.4)
61
+ standard-performance (~> 1.8)
58
62
  standard-custom (1.0.2)
59
63
  lint_roller (~> 1.0)
60
64
  rubocop (~> 1.50)
61
- standard-performance (1.4.0)
65
+ standard-performance (1.8.0)
62
66
  lint_roller (~> 1.1)
63
- rubocop-performance (~> 1.21.0)
64
- strscan (3.1.0)
65
- thor (1.3.1)
66
- unicode-display_width (2.5.0)
67
- uri (0.13.0)
67
+ rubocop-performance (~> 1.25.0)
68
+ thor (1.3.2)
69
+ unicode-display_width (3.1.4)
70
+ unicode-emoji (~> 4.0, >= 4.0.4)
71
+ unicode-emoji (4.0.4)
72
+ uri (1.0.3)
68
73
 
69
74
  PLATFORMS
70
75
  ruby
@@ -79,4 +84,4 @@ DEPENDENCIES
79
84
  vultr!
80
85
 
81
86
  BUNDLED WITH
82
- 2.5.10
87
+ 2.6.9
@@ -1,5 +1,6 @@
1
1
  module Vultr
2
2
  class Collection
3
+ include Enumerable
3
4
  attr_reader :data, :total, :next_cursor, :prev_cursor
4
5
 
5
6
  def self.from_response(response, key:, type:)
@@ -18,5 +19,10 @@ module Vultr
18
19
  @next_cursor = next_cursor.empty? ? nil : next_cursor
19
20
  @prev_cursor = prev_cursor.empty? ? nil : prev_cursor
20
21
  end
22
+
23
+ def each
24
+ return enum_for(:each) unless block_given?
25
+ @data.each(&block)
26
+ end
21
27
  end
22
28
  end
data/lib/vultr/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Vultr
2
- VERSION = "2.0.0"
2
+ VERSION = "2.1.1"
3
3
  end
metadata CHANGED
@@ -1,15 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vultr
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.0
4
+ version: 2.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gao Jiangmiao
8
8
  - Chris Oliver
9
- autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
- date: 2024-05-31 00:00:00.000000000 Z
11
+ date: 1980-01-02 00:00:00.000000000 Z
13
12
  dependencies:
14
13
  - !ruby/object:Gem::Dependency
15
14
  name: faraday
@@ -276,7 +275,6 @@ homepage: https://github.com/tolbkni/vultr.rb
276
275
  licenses:
277
276
  - MIT
278
277
  metadata: {}
279
- post_install_message:
280
278
  rdoc_options: []
281
279
  require_paths:
282
280
  - lib
@@ -291,8 +289,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
291
289
  - !ruby/object:Gem::Version
292
290
  version: '0'
293
291
  requirements: []
294
- rubygems_version: 3.5.10
295
- signing_key:
292
+ rubygems_version: 3.6.9
296
293
  specification_version: 4
297
294
  summary: Ruby bindings for VULTR API.
298
295
  test_files: []