dependabot-git_submodules 0.86.5 → 0.86.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/dependabot/git_submodules/file_fetcher.rb +14 -5
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2120aee27d7b74f0943268c797e28660384b2d7ca5828d94e19e3dc324b94a76
|
4
|
+
data.tar.gz: 296bf690c7e0f7066fc5e3c6c0cbc8ab6e77786315e49dede516b4d25dc6a4dc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f6afaf1b996d8203b8301c686c9a45727d6d426e34cbfff731a8bdf96f49ceb225610844b7fe8cbf8321b890fe5d3f59068f0e29014da44fcfc9ddee05d43ce6
|
7
|
+
data.tar.gz: 62ca92d9d335f869234dfac1cb3656dd49e0c601c9c3b4fa0e62685398623a3b7c98ea8eb54703d4759e6c29fea87f46a5fbc0e4e8e80003ca415ba289adf7af
|
@@ -47,11 +47,7 @@ module Dependabot
|
|
47
47
|
cleanpath.to_path.gsub(%r{^/*}, "")
|
48
48
|
sha = case source.provider
|
49
49
|
when "github"
|
50
|
-
|
51
|
-
repo,
|
52
|
-
path: path,
|
53
|
-
ref: commit
|
54
|
-
).sha
|
50
|
+
fetch_github_submodule_commit(path)
|
55
51
|
when "gitlab"
|
56
52
|
tmp_path = path.gsub(%r{^/*}, "")
|
57
53
|
gitlab_client.get_file(repo, tmp_path, commit).blob_id
|
@@ -67,6 +63,19 @@ module Dependabot
|
|
67
63
|
rescue Octokit::NotFound, Gitlab::Error::NotFound
|
68
64
|
raise Dependabot::DependencyFileNotFound, path
|
69
65
|
end
|
66
|
+
|
67
|
+
def fetch_github_submodule_commit(path)
|
68
|
+
content = github_client_for_source.contents(
|
69
|
+
repo,
|
70
|
+
path: path,
|
71
|
+
ref: commit
|
72
|
+
)
|
73
|
+
if content.is_a?(Array) || content.type != "submodule"
|
74
|
+
raise Dependabot::DependencyFileNotFound, path
|
75
|
+
end
|
76
|
+
|
77
|
+
content.sha
|
78
|
+
end
|
70
79
|
end
|
71
80
|
end
|
72
81
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dependabot-git_submodules
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.86.
|
4
|
+
version: 0.86.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dependabot
|
@@ -16,14 +16,14 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - '='
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 0.86.
|
19
|
+
version: 0.86.6
|
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.86.
|
26
|
+
version: 0.86.6
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: byebug
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|