Skip to content

Instantly share code, notes, and snippets.

Created Nov 25, 2014
What would you like to do?
Generate Molinillo integration spec indices from CocoaPods
require 'cocoapods'
master = Pod::SourcesManager.master.first
pods = {}
# names = master.pods
names = %w(AFAmazonS3Client AFNetworking AFOAuth2Client CargoBay)
names.each do |n|
pods[n] = master.versions(n).map { |v| master.specification(n, v) }.map { |s| {name:, version: s.version, dependencies: Hash[ { |d| [, d.requirement] }]} }
require 'json''spec/resolver_integration_specs/index/three_way_conflict.json', 'w') { |f| f.puts JSON.pretty_generate pods }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment