Sha256: d09e391c7ff12a43a39dd48fdac328894228cba06bf0df62626afff836c5e56a

Contents?: true

Size: 499 Bytes

Versions: 2

Compression:

Stored size: 499 Bytes

Contents

module Codestatus
  class RepositoryResolver
    class UserDefinedResolver
      def self.definitions
        @definitions ||= {
          'rubygems/apartment': Codestatus::PackageRepository.new(github: 'influitive/apartment'),
          'rubygems/octokit': Codestatus::PackageRepository.new(github: 'octokit/octokit.rb'),
        }
      end

      def resolve(registry:, package:)
        key = [registry, package].join('/')

        self.class.definitions[key.to_sym]
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
codestatus-0.1.1 lib/codestatus/repository_resolver/user_defined_resolver.rb
codestatus-0.1.0 lib/codestatus/repository_resolver/user_defined_resolver.rb