dependabot-git_submodules 0.288.0 → 0.289.0

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: badc29da8070ae1bc9ca372101ca2bb6683caf88b70937873767b09f4176e59d
4
- data.tar.gz: 89b7291586ae39955a275e9c5fe9b00564d67db2c82c6505342c273950392b37
3
+ metadata.gz: 428836bcd533e8c4560a3bbc89d138aa45966b934079e4c7de877192b381570b
4
+ data.tar.gz: 38973c3cd615b33e95286e9539189f5f216770f00d89880d40f08bd38f5eff72
5
5
  SHA512:
6
- metadata.gz: f24b5a0ee8e69e6a1fcf9b0bc4ecf5dde26df58967490b8d13208fc32a6c5c391690bf157d14d1b9963c6f5eaaa97c698f3ea304660026c1ce737c3da1e60c33
7
- data.tar.gz: 6ba349eadee7eda0e4f666fc6be5ac6c5e042b2bf22bb3f8a566da5f05959e22b8eee2d2d426f6e4fdf027f4517afebae8b40102802a66553d0cb6d99e732b86
6
+ metadata.gz: 4ae9ccdd50fbf477d23609f7ec19cd57ba52a14df689d8b94d18d7967487ecb6833b2be4a0426c579e767df4564209eecc3be45ed92aea72af618e6520b5cd31
7
+ data.tar.gz: 105ecb26337e7a5b7aa08cca8b46ce301117bd1dc95385c0f81ff0c9c9e2997a70575b2acab45b39c970119f5edf0531392b0b0be637c1cddfe7312c2671787e
@@ -8,6 +8,7 @@ require "dependabot/dependency"
8
8
  require "dependabot/file_parsers"
9
9
  require "dependabot/file_parsers/base"
10
10
  require "dependabot/shared_helpers"
11
+ require "dependabot/git_submodules/package_manager"
11
12
 
12
13
  module Dependabot
13
14
  module GitSubmodules
@@ -42,6 +43,16 @@ module Dependabot
42
43
  end
43
44
  end
44
45
 
46
+ sig { returns(Ecosystem) }
47
+ def ecosystem
48
+ @ecosystem ||= T.let(begin
49
+ Ecosystem.new(
50
+ name: ECOSYSTEM,
51
+ package_manager: package_manager
52
+ )
53
+ end, T.nilable(Dependabot::Ecosystem))
54
+ end
55
+
45
56
  private
46
57
 
47
58
  sig { params(url: String).returns(String) }
@@ -77,6 +88,25 @@ module Dependabot
77
88
  raise "No #{filename}!" unless get_original_file(filename)
78
89
  end
79
90
  end
91
+
92
+ sig { returns(Ecosystem::VersionManager) }
93
+ def package_manager
94
+ @package_manager ||= T.let(
95
+ PackageManager.new(T.must(git_version)),
96
+ T.nilable(Dependabot::GitSubmodules::PackageManager)
97
+ )
98
+ end
99
+
100
+ sig { returns(T.nilable(String)) }
101
+ def git_version
102
+ @git_version ||= T.let(
103
+ begin
104
+ version = SharedHelpers.run_shell_command("git --version")
105
+ version.match(Dependabot::Ecosystem::VersionManager::DEFAULT_VERSION_PATTERN)&.captures&.first
106
+ end,
107
+ T.nilable(String)
108
+ )
109
+ end
80
110
  end
81
111
  end
82
112
  end
@@ -0,0 +1,41 @@
1
+ # typed: strong
2
+ # frozen_string_literal: true
3
+
4
+ require "sorbet-runtime"
5
+ require "dependabot/ecosystem"
6
+ require "dependabot/git_submodules/version"
7
+
8
+ module Dependabot
9
+ module GitSubmodules
10
+ ECOSYSTEM = "git_submodules"
11
+ PACKAGE_MANAGER = "git_submodules"
12
+ SUPPORTED_GIT_VERSIONS = T.let([].freeze, T::Array[Dependabot::Version])
13
+
14
+ # When a version is going to be unsupported, it will be added here
15
+ DEPRECATED_GIT_VERSIONS = T.let([].freeze, T::Array[Dependabot::Version])
16
+
17
+ class PackageManager < Dependabot::Ecosystem::VersionManager
18
+ extend T::Sig
19
+
20
+ sig { params(raw_version: String).void }
21
+ def initialize(raw_version)
22
+ super(
23
+ PACKAGE_MANAGER,
24
+ Version.new(raw_version),
25
+ DEPRECATED_GIT_VERSIONS,
26
+ SUPPORTED_GIT_VERSIONS
27
+ )
28
+ end
29
+
30
+ sig { returns(T::Boolean) }
31
+ def deprecated?
32
+ false
33
+ end
34
+
35
+ sig { returns(T::Boolean) }
36
+ def unsupported?
37
+ false
38
+ end
39
+ end
40
+ end
41
+ end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dependabot-git_submodules
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.288.0
4
+ version: 0.289.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dependabot
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-11-21 00:00:00.000000000 Z
11
+ date: 2024-12-05 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.288.0
19
+ version: 0.289.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.288.0
26
+ version: 0.289.0
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: parseconfig
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -267,6 +267,7 @@ files:
267
267
  - lib/dependabot/git_submodules/file_parser.rb
268
268
  - lib/dependabot/git_submodules/file_updater.rb
269
269
  - lib/dependabot/git_submodules/metadata_finder.rb
270
+ - lib/dependabot/git_submodules/package_manager.rb
270
271
  - lib/dependabot/git_submodules/requirement.rb
271
272
  - lib/dependabot/git_submodules/update_checker.rb
272
273
  - lib/dependabot/git_submodules/version.rb
@@ -275,7 +276,7 @@ licenses:
275
276
  - MIT
276
277
  metadata:
277
278
  bug_tracker_uri: https://github.com/dependabot/dependabot-core/issues
278
- changelog_uri: https://github.com/dependabot/dependabot-core/releases/tag/v0.288.0
279
+ changelog_uri: https://github.com/dependabot/dependabot-core/releases/tag/v0.289.0
279
280
  post_install_message:
280
281
  rdoc_options: []
281
282
  require_paths: