Class: Dependabot::Deno::FileFetcher
- Inherits:
-
FileFetchers::Base
- Object
- FileFetchers::Base
- Dependabot::Deno::FileFetcher
- Extended by:
- T::Sig
- Defined in:
- lib/dependabot/deno/file_fetcher.rb
Constant Summary collapse
- MANIFEST_FILENAMES =
T.let(%w(deno.json deno.jsonc).freeze, T::Array[String])
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.required_files_in?(filenames) ⇒ Boolean
20 21 22 |
# File 'lib/dependabot/deno/file_fetcher.rb', line 20 def self.required_files_in?(filenames) filenames.any? { |f| MANIFEST_FILENAMES.include?(f) } end |
.required_files_message ⇒ Object
15 16 17 |
# File 'lib/dependabot/deno/file_fetcher.rb', line 15 def self. "Repo must contain a deno.json or deno.jsonc." end |
Instance Method Details
#ecosystem_versions ⇒ Object
40 41 42 |
# File 'lib/dependabot/deno/file_fetcher.rb', line 40 def ecosystem_versions nil end |
#fetch_files ⇒ Object
25 26 27 28 29 30 31 32 33 34 35 36 37 |
# File 'lib/dependabot/deno/file_fetcher.rb', line 25 def fetch_files unless allow_beta_ecosystems? raise Dependabot::DependencyFileNotFound.new( nil, "Deno ecosystem support is in beta. Set enable-beta-ecosystems to use it." ) end fetched_files = [] fetched_files << manifest_file fetched_files << lockfile if lockfile fetched_files end |