Sha256: 15d6bf8f6b6c633e980faf42fa35e0559631dc79e1f6b4666fe14f84ac787637

Contents?: true

Size: 998 Bytes

Versions: 30

Compression:

Stored size: 998 Bytes

Contents

# frozen_string_literal: true

require "dependabot/file_parsers/ruby/bundler"
require "dependabot/file_parsers/java_script/npm_and_yarn"
require "dependabot/file_parsers/php/composer"
require "dependabot/file_parsers/elixir/hex"
require "dependabot/file_parsers/go/dep"
require "dependabot/file_parsers/go/modules"

module Dependabot
  module FileParsers
    @file_parsers = {
      "bundler" => FileParsers::Ruby::Bundler,
      "npm_and_yarn" => FileParsers::JavaScript::NpmAndYarn,
      "composer" => FileParsers::Php::Composer,
      "hex" => FileParsers::Elixir::Hex,
      "dep" => FileParsers::Go::Dep,
      "go_modules" => FileParsers::Go::Modules
    }

    def self.for_package_manager(package_manager)
      file_parser = @file_parsers[package_manager]
      return file_parser if file_parser

      raise "Unsupported package_manager #{package_manager}"
    end

    def self.register(package_manager, file_parser)
      @file_parsers[package_manager] = file_parser
    end
  end
end

Version data entries

30 entries across 30 versions & 1 rubygems

Version Path
dependabot-core-0.86.25 lib/dependabot/file_parsers.rb
dependabot-core-0.86.24 lib/dependabot/file_parsers.rb
dependabot-core-0.86.23 lib/dependabot/file_parsers.rb
dependabot-core-0.86.22 lib/dependabot/file_parsers.rb
dependabot-core-0.86.21 lib/dependabot/file_parsers.rb
dependabot-core-0.86.20 lib/dependabot/file_parsers.rb
dependabot-core-0.86.19 lib/dependabot/file_parsers.rb
dependabot-core-0.86.18 lib/dependabot/file_parsers.rb
dependabot-core-0.86.17 lib/dependabot/file_parsers.rb
dependabot-core-0.86.16 lib/dependabot/file_parsers.rb
dependabot-core-0.86.15 lib/dependabot/file_parsers.rb
dependabot-core-0.86.14 lib/dependabot/file_parsers.rb
dependabot-core-0.86.13 lib/dependabot/file_parsers.rb
dependabot-core-0.86.12 lib/dependabot/file_parsers.rb
dependabot-core-0.86.11 lib/dependabot/file_parsers.rb
dependabot-core-0.86.10 lib/dependabot/file_parsers.rb
dependabot-core-0.86.9 lib/dependabot/file_parsers.rb
dependabot-core-0.86.8 lib/dependabot/file_parsers.rb
dependabot-core-0.86.7 lib/dependabot/file_parsers.rb
dependabot-core-0.86.6 lib/dependabot/file_parsers.rb