dependabot-elm 0.302.0 → 0.303.0
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f599abfc9246cc39740573e6cdac0b6a71f8fab0937affdd7f0236f9cda90844
|
4
|
+
data.tar.gz: 3a7d68355aa1e6d7ebc9bf60325b5078ef4dee3f0cbf0d32971692db9955ea6c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cfad6242b44c08638886c4fa0c4fcb6949244165454201b0c7c29faad4b530aee497bc7f822aa85e83f690dd669d21609bcd508d6f53802b953af234afadcc10
|
7
|
+
data.tar.gz: 6a6b2d1acb4c282b593765003c4e84aeb499e5f2f1bfa8a609807599dcd945c822d57c88ac1a7d8395817afbc8e451aa636fc14023d5a526114b1159cf35b3c1
|
@@ -1,6 +1,8 @@
|
|
1
|
-
# typed:
|
1
|
+
# typed: strict
|
2
2
|
# frozen_string_literal: true
|
3
3
|
|
4
|
+
require "sorbet-runtime"
|
5
|
+
|
4
6
|
require "dependabot/dependency"
|
5
7
|
require "dependabot/errors"
|
6
8
|
require "dependabot/file_parsers"
|
@@ -12,10 +14,12 @@ require "dependabot/elm/package_manager"
|
|
12
14
|
module Dependabot
|
13
15
|
module Elm
|
14
16
|
class FileParser < Dependabot::FileParsers::Base
|
17
|
+
extend T::Sig
|
15
18
|
require "dependabot/file_parsers/base/dependency_set"
|
16
19
|
|
17
20
|
DEPENDENCY_TYPES = %w(dependencies test-dependencies).freeze
|
18
21
|
|
22
|
+
sig { override.returns(T::Array[Dependabot::Dependency]) }
|
19
23
|
def parse
|
20
24
|
dependency_set = DependencySet.new
|
21
25
|
|
@@ -101,6 +105,7 @@ module Dependabot
|
|
101
105
|
# For docs on elm.json, see:
|
102
106
|
# https://github.com/elm/compiler/blob/master/docs/elm.json/application.md
|
103
107
|
# https://github.com/elm/compiler/blob/master/docs/elm.json/package.md
|
108
|
+
sig { returns(Dependabot::FileParsers::Base::DependencySet) }
|
104
109
|
def elm_json_dependencies
|
105
110
|
dependency_set = DependencySet.new
|
106
111
|
|
@@ -131,6 +136,15 @@ module Dependabot
|
|
131
136
|
dependency_set
|
132
137
|
end
|
133
138
|
|
139
|
+
sig do
|
140
|
+
params(
|
141
|
+
name: String,
|
142
|
+
group: String,
|
143
|
+
requirement: String,
|
144
|
+
direct: T::Boolean
|
145
|
+
)
|
146
|
+
.returns(Dependabot::Dependency)
|
147
|
+
end
|
134
148
|
def build_elm_json_dependency(name:, group:, requirement:, direct:)
|
135
149
|
requirements = [{
|
136
150
|
requirement: requirement,
|
@@ -159,6 +173,7 @@ module Dependabot
|
|
159
173
|
raise "No #{MANIFEST_FILE}!"
|
160
174
|
end
|
161
175
|
|
176
|
+
sig { params(version_requirement: String).returns(T.nilable(Gem::Version)) }
|
162
177
|
def version_for(version_requirement)
|
163
178
|
req = Dependabot::Elm::Requirement.new(version_requirement)
|
164
179
|
|
@@ -167,12 +182,14 @@ module Dependabot
|
|
167
182
|
req.requirements.first.last
|
168
183
|
end
|
169
184
|
|
185
|
+
sig { returns(T::Hash[String, T.untyped]) }
|
170
186
|
def parsed_elm_json
|
171
|
-
@parsed_elm_json ||= JSON.parse(elm_json
|
187
|
+
@parsed_elm_json ||= T.let(JSON.parse(T.must(elm_json&.content)), T.nilable(T::Hash[String, T.untyped]))
|
172
188
|
rescue JSON::ParserError
|
173
189
|
raise Dependabot::DependencyFileNotParseable, elm_json&.path || MANIFEST_FILE
|
174
190
|
end
|
175
191
|
|
192
|
+
sig { returns(T.nilable(Dependabot::DependencyFile)) }
|
176
193
|
def elm_json
|
177
194
|
@elm_json ||= T.let(
|
178
195
|
get_original_file(MANIFEST_FILE),
|
@@ -1,6 +1,8 @@
|
|
1
|
-
# typed:
|
1
|
+
# typed: strong
|
2
2
|
# frozen_string_literal: true
|
3
3
|
|
4
|
+
require "sorbet-runtime"
|
5
|
+
|
4
6
|
require "dependabot/file_updaters"
|
5
7
|
require "dependabot/file_updaters/base"
|
6
8
|
|
@@ -9,12 +11,14 @@ module Dependabot
|
|
9
11
|
class FileUpdater < Dependabot::FileUpdaters::Base
|
10
12
|
require_relative "file_updater/elm_json_updater"
|
11
13
|
|
14
|
+
sig { override.returns(T::Array[Regexp]) }
|
12
15
|
def self.updated_files_regex
|
13
16
|
[
|
14
17
|
/^elm\.json$/
|
15
18
|
]
|
16
19
|
end
|
17
20
|
|
21
|
+
sig { override.returns(T::Array[Dependabot::DependencyFile]) }
|
18
22
|
def updated_dependency_files
|
19
23
|
updated_files = []
|
20
24
|
|
@@ -24,7 +28,7 @@ module Dependabot
|
|
24
28
|
updated_files <<
|
25
29
|
updated_file(
|
26
30
|
file: file,
|
27
|
-
content: updated_elm_json_content(file)
|
31
|
+
content: T.must(updated_elm_json_content(file))
|
28
32
|
)
|
29
33
|
end
|
30
34
|
|
@@ -35,12 +39,14 @@ module Dependabot
|
|
35
39
|
|
36
40
|
private
|
37
41
|
|
42
|
+
sig { override.void }
|
38
43
|
def check_required_files
|
39
44
|
return if elm_json_files.any?
|
40
45
|
|
41
46
|
raise "No #{MANIFEST_FILE}"
|
42
47
|
end
|
43
48
|
|
49
|
+
sig { params(file: Dependabot::DependencyFile).returns(T.nilable(String)) }
|
44
50
|
def updated_elm_json_content(file)
|
45
51
|
ElmJsonUpdater.new(
|
46
52
|
dependencies: dependencies,
|
@@ -48,6 +54,7 @@ module Dependabot
|
|
48
54
|
).updated_content
|
49
55
|
end
|
50
56
|
|
57
|
+
sig { returns(T::Array[Dependabot::DependencyFile]) }
|
51
58
|
def elm_json_files
|
52
59
|
dependency_files.select { |f| f.name.end_with?(MANIFEST_FILE) }
|
53
60
|
end
|
@@ -1,6 +1,8 @@
|
|
1
|
-
# typed:
|
1
|
+
# typed: strong
|
2
2
|
# frozen_string_literal: true
|
3
3
|
|
4
|
+
require "sorbet-runtime"
|
5
|
+
|
4
6
|
require "dependabot/metadata_finders"
|
5
7
|
require "dependabot/metadata_finders/base"
|
6
8
|
require "dependabot/source"
|
@@ -8,8 +10,11 @@ require "dependabot/source"
|
|
8
10
|
module Dependabot
|
9
11
|
module Elm
|
10
12
|
class MetadataFinder < Dependabot::MetadataFinders::Base
|
13
|
+
extend T::Sig
|
14
|
+
|
11
15
|
private
|
12
16
|
|
17
|
+
sig { override.returns(T.nilable(Dependabot::Source)) }
|
13
18
|
def look_up_source
|
14
19
|
# For Elm 0.18 an elm-package is guaranteed to be `owner/name`
|
15
20
|
# on github. For 0.19 a lot will change, including the name of
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dependabot-elm
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.303.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dependabot
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2025-03-
|
11
|
+
date: 2025-03-27 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.
|
19
|
+
version: 0.303.0
|
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.
|
26
|
+
version: 0.303.0
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: debug
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -156,14 +156,14 @@ dependencies:
|
|
156
156
|
requirements:
|
157
157
|
- - "~>"
|
158
158
|
- !ruby/object:Gem::Version
|
159
|
-
version: 0.8.
|
159
|
+
version: 0.8.7
|
160
160
|
type: :development
|
161
161
|
prerelease: false
|
162
162
|
version_requirements: !ruby/object:Gem::Requirement
|
163
163
|
requirements:
|
164
164
|
- - "~>"
|
165
165
|
- !ruby/object:Gem::Version
|
166
|
-
version: 0.8.
|
166
|
+
version: 0.8.7
|
167
167
|
- !ruby/object:Gem::Dependency
|
168
168
|
name: simplecov
|
169
169
|
requirement: !ruby/object:Gem::Requirement
|
@@ -261,7 +261,7 @@ licenses:
|
|
261
261
|
- MIT
|
262
262
|
metadata:
|
263
263
|
bug_tracker_uri: https://github.com/dependabot/dependabot-core/issues
|
264
|
-
changelog_uri: https://github.com/dependabot/dependabot-core/releases/tag/v0.
|
264
|
+
changelog_uri: https://github.com/dependabot/dependabot-core/releases/tag/v0.303.0
|
265
265
|
post_install_message:
|
266
266
|
rdoc_options: []
|
267
267
|
require_paths:
|