Commit 36e302a1 authored by Orta Therox's avatar Orta Therox

[Create] Pass the Pod::version as a ENV var for the configure scripts to read

parent 534c997b
...@@ -33,6 +33,10 @@ To install release candidates run `[sudo] gem install cocoapods --pre` ...@@ -33,6 +33,10 @@ To install release candidates run `[sudo] gem install cocoapods --pre`
[benasher44](https://github.com/benasher44) [benasher44](https://github.com/benasher44)
[#5747](https://github.com/CocoaPods/CocoaPods/pull/5747) [#5747](https://github.com/CocoaPods/CocoaPods/pull/5747)
* Pass the version of CocoaPods to `pod lib create`'s configure script.
[orta](https://github.com/orta)
[#5787](https://github.com/CocoaPods/CocoaPods/pull/5787)
##### Bug Fixes ##### Bug Fixes
* Hash scope suffixes if they are over 50 characters to prevent file paths from being too long. * Hash scope suffixes if they are over 50 characters to prevent file paths from being too long.
......
...@@ -75,7 +75,7 @@ module Pod ...@@ -75,7 +75,7 @@ module Pod
UI.section("Configuring #{@name} template.") do UI.section("Configuring #{@name} template.") do
Dir.chdir(@name) do Dir.chdir(@name) do
if File.exist?('configure') if File.exist?('configure')
system('./configure', @name, *@additional_args) system({ 'COCOAPODS_VERSION' => Pod::Version }, './configure', @name, *@additional_args)
else else
UI.warn 'Template does not have a configure file.' UI.warn 'Template does not have a configure file.'
end end
......
...@@ -34,7 +34,7 @@ module Pod ...@@ -34,7 +34,7 @@ module Pod
dir = SpecHelper.temporary_directory + 'TestPod' dir = SpecHelper.temporary_directory + 'TestPod'
dir.mkpath dir.mkpath
File.stubs(:exist?).with('configure').returns(true) File.stubs(:exist?).with('configure').returns(true)
@sut.any_instance.expects(:system).with('./configure', 'TestPod', 'foo').once @sut.any_instance.expects(:system).with({ 'COCOAPODS_VERSION' => Pod::Version }, './configure', 'TestPod', 'foo').once
run_command('lib', 'create', 'TestPod', 'foo', '--verbose') run_command('lib', 'create', 'TestPod', 'foo', '--verbose')
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