dependabot-terraform 0.261.0 → 0.261.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/dependabot/terraform/requirement.rb +8 -5
- metadata +5 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f43110753b0a724a429bc09a65a8a86f311147c5611dfd03fdc6a4c51f900a88
|
4
|
+
data.tar.gz: d1b548612657b50cefcdf4fefed24a1f1ede3cec7c1f98679d8879ee894d9953
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2e4958e34241b4bf263f090518cb3d510e7a9b4945842b9710e6d7b2bcab9947f9b475a017007c14b4d15b65f3d496086cd6f3e83b940cdc8735780963903b09
|
7
|
+
data.tar.gz: 0420b3d5b33b2ceec10a5c752a2b49c40660d409a6a1e20f019964f8155e7272eadbe431109b69bc1f3b8cd6b6e2ccddd11794a8f0cf1740dc9eed439e6638a8
|
@@ -1,4 +1,4 @@
|
|
1
|
-
# typed:
|
1
|
+
# typed: strict
|
2
2
|
# frozen_string_literal: true
|
3
3
|
|
4
4
|
require "sorbet-runtime"
|
@@ -11,13 +11,15 @@ require "dependabot/terraform/version"
|
|
11
11
|
module Dependabot
|
12
12
|
module Terraform
|
13
13
|
class Requirement < Dependabot::Requirement
|
14
|
+
extend T::Sig
|
14
15
|
# Override regex PATTERN from Gem::Requirement to add support for the
|
15
16
|
# optional 'v' prefix to release tag names, which Terraform supports.
|
16
17
|
# https://www.terraform.io/docs/registry/modules/publish.html#requirements
|
17
|
-
OPERATORS = OPS.keys.map { |key| Regexp.quote(key) }.join("|").freeze
|
18
|
-
PATTERN_RAW = "\\s*(#{OPERATORS})?\\s*v?(#{Gem::Version::VERSION_PATTERN})\\s*".freeze
|
18
|
+
OPERATORS = T.let(OPS.keys.map { |key| Regexp.quote(key) }.join("|").freeze, String)
|
19
|
+
PATTERN_RAW = T.let("\\s*(#{OPERATORS})?\\s*v?(#{Gem::Version::VERSION_PATTERN})\\s*".freeze, String)
|
19
20
|
PATTERN = /\A#{PATTERN_RAW}\z/
|
20
21
|
|
22
|
+
sig { params(obj: T.any(String, Gem::Version)).returns(T::Array[T.any(String, Version)]) }
|
21
23
|
def self.parse(obj)
|
22
24
|
return ["=", Version.new(obj.to_s)] if obj.is_a?(Gem::Version)
|
23
25
|
|
@@ -28,7 +30,7 @@ module Dependabot
|
|
28
30
|
|
29
31
|
return DefaultRequirement if matches[1] == ">=" && matches[2] == "0"
|
30
32
|
|
31
|
-
[matches[1] || "=", Terraform::Version.new(
|
33
|
+
[matches[1] || "=", Terraform::Version.new(matches[2])]
|
32
34
|
end
|
33
35
|
|
34
36
|
# For consistency with other languages, we define a requirements array.
|
@@ -36,11 +38,12 @@ module Dependabot
|
|
36
38
|
# always contains a single element.
|
37
39
|
sig { override.params(requirement_string: T.nilable(String)).returns(T::Array[Requirement]) }
|
38
40
|
def self.requirements_array(requirement_string)
|
39
|
-
[new(requirement_string)]
|
41
|
+
[new(requirement_string.to_s)]
|
40
42
|
end
|
41
43
|
|
42
44
|
# Patches Gem::Requirement to make it accept requirement strings like
|
43
45
|
# "~> 4.2.5, >= 4.2.5.1" without first needing to split them.
|
46
|
+
sig { params(requirements: T.any(String, T::Array[String])).void }
|
44
47
|
def initialize(*requirements)
|
45
48
|
requirements = requirements.flatten.flat_map do |req_string|
|
46
49
|
req_string.split(",").map(&:strip)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dependabot-terraform
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.261.
|
4
|
+
version: 0.261.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dependabot
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-06-
|
11
|
+
date: 2024-06-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: dependabot-common
|
@@ -16,14 +16,14 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - '='
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 0.261.
|
19
|
+
version: 0.261.1
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - '='
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: 0.261.
|
26
|
+
version: 0.261.1
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: debug
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -260,7 +260,7 @@ licenses:
|
|
260
260
|
- MIT
|
261
261
|
metadata:
|
262
262
|
bug_tracker_uri: https://github.com/dependabot/dependabot-core/issues
|
263
|
-
changelog_uri: https://github.com/dependabot/dependabot-core/releases/tag/v0.261.
|
263
|
+
changelog_uri: https://github.com/dependabot/dependabot-core/releases/tag/v0.261.1
|
264
264
|
post_install_message:
|
265
265
|
rdoc_options: []
|
266
266
|
require_paths:
|