Rename the `local` option of the Podfile to `path` #971

Closed
fabiopelosin opened this Issue Apr 15, 2013 · 15 comments

Comments

Projects
None yet
5 participants
@fabiopelosin
Member

fabiopelosin commented Apr 15, 2013

It would be consistent with Bundler and a more appropriate name.

@supermarin

This comment has been minimized.

Show comment Hide comment
@supermarin

supermarin Apr 16, 2013

Member

solved in CocoaPods/Core#16

Member

supermarin commented Apr 16, 2013

solved in CocoaPods/Core#16

@supermarin supermarin closed this Apr 16, 2013

@supermarin supermarin reopened this Apr 16, 2013

@jasl8r

This comment has been minimized.

Show comment Hide comment
@jasl8r

jasl8r Apr 19, 2013

Contributor

Using the :path option doesn't work for me. It looks like :local is used exclusively in a few places, in particular in podspec_path:

https://github.com/CocoaPods/CocoaPods/blob/master/lib/cocoapods/external_sources.rb#L343

Contributor

jasl8r commented Apr 19, 2013

Using the :path option doesn't work for me. It looks like :local is used exclusively in a few places, in particular in podspec_path:

https://github.com/CocoaPods/CocoaPods/blob/master/lib/cocoapods/external_sources.rb#L343

@fabiopelosin

This comment has been minimized.

Show comment Hide comment
@fabiopelosin

fabiopelosin Apr 19, 2013

Member

@jasl8r Are you using CocoaPods head?

Member

fabiopelosin commented Apr 19, 2013

@jasl8r Are you using CocoaPods head?

@jasl8r

This comment has been minimized.

Show comment Hide comment
@jasl8r

jasl8r Apr 19, 2013

Contributor

Yes, with a very simple setup it fails.

Directory structure:

src/Podfile
src/Project.xcodeproj
src/libone
src/libone/one.podspec
src/libone/src/...

Podfile:

pod 'one', :path => 'libone'

Installation fails:

pod install --no-repo-update --verbose

Analyzing dependencies

Fetching external sources
-> Fetching podspec for `one` from ``
[!] No podspec found for `one` in ``

/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/external_sources.rb:351:in `podspec_path'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/external_sources.rb:323:in `block in fetch'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/user_interface.rb:73:in `titled_section'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/external_sources.rb:322:in `fetch'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/installer/analyzer.rb:258:in `block (2 levels) in fetch_external_sources'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/installer/analyzer.rb:256:in `each'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/installer/analyzer.rb:256:in `block in fetch_external_sources'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/user_interface.rb:52:in `section'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/installer/analyzer.rb:255:in `fetch_external_sources'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/installer/analyzer.rb:55:in `analyze'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/installer.rb:167:in `analyze'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/installer.rb:92:in `block in resolve_dependencies'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/user_interface.rb:52:in `section'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/installer.rb:91:in `resolve_dependencies'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/installer.rb:84:in `install!'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/command/project.rb:40:in `run_install_with_update'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/command/project.rb:70:in `run'
/Users/jasl8r/.rvm/gems/ruby-1.9.3-p392/gems/claide-0.2.0/lib/claide.rb:535:in `run'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/command.rb:48:in `run'
/Users/jasl8r/Development/cocoapods/CocoaPods/bin/pod:16:in `<main>'

With :local everything is fine.

Updating the declared_path value to use the :local or :path value solves the initial installation failure. However, changing the Podfile to add another dependency, and re-running pod install causes a different failure. Interestingly, pod update succeeds with this change.

Contributor

jasl8r commented Apr 19, 2013

Yes, with a very simple setup it fails.

Directory structure:

src/Podfile
src/Project.xcodeproj
src/libone
src/libone/one.podspec
src/libone/src/...

Podfile:

pod 'one', :path => 'libone'

Installation fails:

pod install --no-repo-update --verbose

Analyzing dependencies

Fetching external sources
-> Fetching podspec for `one` from ``
[!] No podspec found for `one` in ``

/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/external_sources.rb:351:in `podspec_path'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/external_sources.rb:323:in `block in fetch'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/user_interface.rb:73:in `titled_section'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/external_sources.rb:322:in `fetch'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/installer/analyzer.rb:258:in `block (2 levels) in fetch_external_sources'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/installer/analyzer.rb:256:in `each'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/installer/analyzer.rb:256:in `block in fetch_external_sources'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/user_interface.rb:52:in `section'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/installer/analyzer.rb:255:in `fetch_external_sources'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/installer/analyzer.rb:55:in `analyze'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/installer.rb:167:in `analyze'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/installer.rb:92:in `block in resolve_dependencies'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/user_interface.rb:52:in `section'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/installer.rb:91:in `resolve_dependencies'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/installer.rb:84:in `install!'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/command/project.rb:40:in `run_install_with_update'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/command/project.rb:70:in `run'
/Users/jasl8r/.rvm/gems/ruby-1.9.3-p392/gems/claide-0.2.0/lib/claide.rb:535:in `run'
/Users/jasl8r/Development/cocoapods/CocoaPods/lib/cocoapods/command.rb:48:in `run'
/Users/jasl8r/Development/cocoapods/CocoaPods/bin/pod:16:in `<main>'

With :local everything is fine.

Updating the declared_path value to use the :local or :path value solves the initial installation failure. However, changing the Podfile to add another dependency, and re-running pod install causes a different failure. Interestingly, pod update succeeds with this change.

@alloy

This comment has been minimized.

Show comment Hide comment
@alloy

alloy Apr 19, 2013

Member

Yeah those occurrences should be updated as well.

/cc @mneorr

Member

alloy commented Apr 19, 2013

Yeah those occurrences should be updated as well.

/cc @mneorr

@fabiopelosin

This comment has been minimized.

Show comment Hide comment
@fabiopelosin

fabiopelosin Apr 19, 2013

Member

@jasl8r, sorry... you obviously are using CocoaPods head. Can you verify that my patch actually fixes the issue?

Member

fabiopelosin commented Apr 19, 2013

@jasl8r, sorry... you obviously are using CocoaPods head. Can you verify that my patch actually fixes the issue?

@jasl8r

This comment has been minimized.

Show comment Hide comment
@jasl8r

jasl8r Apr 19, 2013

Contributor

Looks good, thanks.

Contributor

jasl8r commented Apr 19, 2013

Looks good, thanks.

@supermarin

This comment has been minimized.

Show comment Hide comment
@supermarin

supermarin Apr 21, 2013

Member

@irrationalfab thanks for fixing, I was out these days

Member

supermarin commented Apr 21, 2013

@irrationalfab thanks for fixing, I was out these days

@proger

This comment has been minimized.

Show comment Hide comment
@proger

proger May 17, 2013

what's the reason for deprecating this?

proger commented May 17, 2013

what's the reason for deprecating this?

@fabiopelosin

This comment has been minimized.

Show comment Hide comment
@fabiopelosin

fabiopelosin May 17, 2013

Member

The feature was not deprecated it was just renamed to follow the Bundler convention. Also the new name is more informative.

Member

fabiopelosin commented May 17, 2013

The feature was not deprecated it was just renamed to follow the Bundler convention. Also the new name is more informative.

@proger

This comment has been minimized.

Show comment Hide comment
@proger

proger May 17, 2013

[!] The :local option of the Podfile has been renamed to :path and is deprecated.

That's what pod says.

proger commented May 17, 2013

[!] The :local option of the Podfile has been renamed to :path and is deprecated.

That's what pod says.

@fabiopelosin

This comment has been minimized.

Show comment Hide comment
@fabiopelosin

fabiopelosin May 17, 2013

Member

The deprecation just refers to the old syntax and not to the feature.

Member

fabiopelosin commented May 17, 2013

The deprecation just refers to the old syntax and not to the feature.

@proger

This comment has been minimized.

Show comment Hide comment
@proger

proger May 17, 2013

gotcha, thanks. the changelog entry is a bit frustrating though. :)

proger commented May 17, 2013

gotcha, thanks. the changelog entry is a bit frustrating though. :)

@fabiopelosin

This comment has been minimized.

Show comment Hide comment
@fabiopelosin

fabiopelosin May 20, 2013

Member

I've improved it :-) (the other day but I've forgot to comment).

Member

fabiopelosin commented May 20, 2013

I've improved it :-) (the other day but I've forgot to comment).

jzapater pushed a commit to jzapater/CocoaPods that referenced this issue Sep 17, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment