Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

[Config] Support extension for Podfile. #528

Merged
merged 1 commit into from

3 participants

@fabiopelosin

Add extension to the podfile so it can be associated to an UTI in the Mac OS X Launch Services.

@alloy
Owner

Feel free to add it :)

@xslim

What is the reason for doing file extension? As example, Gemfile is without extension, and survives )

@fabiopelosin fabiopelosin merged commit 4b5e91e into from
@fabiopelosin

@alloy Merged :beer:

What is the reason for doing file extension? As example, Gemfile is without extension, and survives

@xslim To my knowledge in Mac OS X you can't associate an application to a file based on the name, you need the extension or you can associate with public.data and *. I wan't to be able to associate all the Podfiles with a dedicated CocoaPods application (https://github.com/irrationalfab/Ikeda).

@alloy
Owner

I’m not yet sure about the scheme, maybe it should be .podfile so it’s more like .podspec, but for now it’s good enough so that you can use it in Ikeda.

@fabiopelosin

What about Dependencies.podfile ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Sep 18, 2012
  1. @fabiopelosin
This page is out of date. Refresh to see the latest.
Showing with 14 additions and 1 deletion.
  1. +7 −1 lib/cocoapods/config.rb
  2. +7 −0 spec/unit/config_spec.rb
View
8 lib/cocoapods/config.rb
@@ -38,7 +38,13 @@ def project_pods_root
end
def project_podfile
- @project_podfile ||= project_root + 'Podfile'
+ unless @project_podfile
+ @project_podfile = project_root + 'Podfile.cocoapods'
+ unless @project_podfile.exist?
+ @project_podfile = project_root + 'Podfile'
+ end
+ end
+ @project_podfile
end
def project_lockfile
View
7 spec/unit/config_spec.rb
@@ -29,6 +29,13 @@
end
end
+ it "returns the path to the project Podfile if specified with the extension" do
+ (temporary_directory + 'Podfile.cocoapods').open('w') { |f| f << '# Yo' }
+ Dir.chdir(temporary_directory) do
+ config.project_podfile.should == Pathname.pwd + 'Podfile.cocoapods'
+ end
+ end
+
it "returns the path to the Pods directory that holds the dependencies" do
config.project_pods_root.should == Pathname.pwd + 'Pods'
end
Something went wrong with that request. Please try again.