Commit 125f2a0b authored by Samuel E. Giddins's avatar Samuel E. Giddins

[Migrator] Update spec checksums in the manifest

parent 9c9e14b9
...@@ -53,13 +53,16 @@ module Pod ...@@ -53,13 +53,16 @@ module Pod
UI.message('Migrating to CocoaPods 0.36') do UI.message('Migrating to CocoaPods 0.36') do
move(sandbox.root + 'Headers/Build', sandbox.root + 'Headers/Private') move(sandbox.root + 'Headers/Build', sandbox.root + 'Headers/Private')
lockfile = sandbox.manifest.to_hash
sandbox.specifications_root.children.each do |child| sandbox.specifications_root.children.each do |child|
next unless child.basename.to_s =~ /\.podspec$/ next unless child.basename.to_s =~ /\.podspec$/
spec = Specification.from_file(child) spec = Specification.from_file(child)
child.delete child.delete
child = Pathname("#{child}.json") child = Pathname("#{child}.json")
File.open(child, 'w') { |f| f.write spec.to_pretty_json } File.open(child, 'w') { |f| f.write spec.to_pretty_json }
lockfile['SPEC CHECKSUMS'][spec.name] = Specification.from_file(child).checksum
end end
File.open(sandbox.manifest_path, 'w') { |f| f.write Lockfile.new(lockfile).to_yaml }
end end
end end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment