joncardasis / cocoapods-user-defined-build-types

⚒ A cocoapods plugin that can selectively sets build type per pod (static/dynamic library, static/dynamic framework)
MIT License
135 stars 10 forks source link

I'm getting error when trying to use plugin in podfile #1

Closed Vitalii-Gozhenko closed 4 years ago

Vitalii-Gozhenko commented 4 years ago
[!] Invalid `Podfile` file: uninitialized constant Pod::Target::BuildType
Did you mean?  Pod::BuildType.
ebgraham commented 4 years ago

same, on this line

  pod 'React', :path => '../node_modules/react-native/', :build_type => :dynamic_framework
dudihisine commented 4 years ago

You can Fix it by going to this folder: /Library/Ruby/Gems/2.6.0/gems/cocoapods-user-defined-build-types-0.0.6/lib/cocoapods-user-defined-build-types

copy the "podfile_options.rb" file to your desktop

change the original file name to "podfile_options_old.rb"

edit the copied file by change the: Pod::Target::BuildType to: Pod::BuildType

save the file. copy&paste it to the folder

you will need Admin permissions so probably you will enter your Mac password couple of times.

ghost commented 4 years ago

Could be due to this issue https://github.com/joncardasis/cocoapods-user-defined-build-types/issues/3

dudihisine commented 4 years ago

Probably, the in version 1.9.1 Cocoapods changed it from 'Pod::Target::BuildType' to 'Pod::BuildType'

joncardasis commented 4 years ago

@dudihisine you're right on the money. Looks like the namespace updated in 1.9.1. I'll begin working on a fix for this.

joncardasis commented 4 years ago

This is now fixed in v0.0.7. See https://github.com/joncardasis/cocoapods-user-defined-build-types/commit/c9077a02f2b79e208b84a1da13a048131f5c92d6.

gelinxiao commented 3 years ago

pod version 1.5.3: has same error