Skip to content

Preview Ruby 4.1 is a preview. It can change before the final release. Switch to Ruby 4.0 →

instance method

Gem::SpecFetcher#search_for_dependency

search_for_dependency(dependency, matching_platform = true, type: nil)

Find and fetch gem name tuples that match dependency.

If matching_platform is false, gems for all platforms are returned.

type overrides the index type derived from dependency. See available_specs for the list of types.