I need to remove a specific CocoaPod from my Xcode project. Browsing similar questions here on Stack Overflow, I ran into situations where the leading answer caused me to remove all my pods from the project and delete the workspace. Another answer suggested I simply needed to delete the pod from my Podfile and then run pod install, but that doesn't work either; I got several errors related to that pod when I went to build the app.
If I check the Pods folder via Finder, the deleted pods are no longer there. However, if I check Pods > Targets via the workspace, I still see the pods I deleted. They are also still in the Pods > pods directory in the workspace.
For now, I've deleted the related pods from the Pods > Targets area and the app builds fine. The pods are still in my Pods > pods directory though. Can I delete those? And, should pod install be handling all this for me in one go?
You deleted specific pods your app. For examples your podfile
target 'AppTargetName' do
use_frameworks!
pod 'Alamofire'
pod 'SwiftyJSON'
pod 'OneSignal'
pod 'Fabric'
end
if You want to delete only Fabric pods, you remove this and terminal commant pod install
So in the last case;
target 'AppTargetName' do
use_frameworks!
pod 'Alamofire'
pod 'SwiftyJSON'
pod 'OneSignal'
end
Good works :)
You want to remove specific pods your app. For examples your podfile
Your podfile have
pod 'FirebaseAuth'
pod 'FirebaseFirestore'
pod 'FirebaseDatabase'
Remove one of your doesn't need (pod 'FirebaseDatabase')
pod 'FirebaseAuth'
pod 'FirebaseFirestore'
Then open the terminal of directory of your project podfile
pod install
Related
After I installed new pods in my file and changed the name.
Xcode no longer detects errors in code I can even write an essay and it won't spot it
Should I change the name back
inside my pod file I see this
target 'Blanket' do
# Comment the next line if you're not using Swift and don't want to use dynamic frameworks
use_frameworks!
# Pods for Flash Chat'
pod 'Firebase'
pod 'Firebase/Auth'
pod 'Firebase/Database'
pod 'SVProgressHUD'
pod 'ChameleonFramework'
pod 'Firebase/Core'
pod 'Firebase/Storage'
end
In the Target part I changed the name but have also changed the name of my file at the same time.
Any ideas?
I have adopted a Swift project from about 6 months ago and am getting the error:
It's probably not an Alamofire issue as changing the order with SwiftlyJSON causes me to get a No such module 'SwiftlyJSON' error.
I have Product -> Clean'd it and rebuilt but nothing seems to work. Here's a copy of the Podfile.
source 'https://github.com/CocoaPods/Specs.git'
platform :ios, "9.3"
use_frameworks!
target 'TatterTwo' do
# pod 'pop', '~> 1.0'
pod 'FBSDKCoreKit'
pod 'FBSDKLoginKit'
pod 'FBSDKShareKit'
pod 'KeychainAccess'
pod 'Alamofire'
pod 'MBProgressHUD'
pod 'SwiftyJSON','3.0.0'
# pod 'Timberjack', '~> 0.0'
end
I am sure I am using the .xcworkspace rather than .xcodeproj
Ok, there might be different reasons behind this error
First, try to stop the build and start again. If this doesn't work then
Open your Podfile, that is supposed to be located inside of the project folder. Podfile configuration. Make sure your target matches the project name. If you did any modification then go to terminal locate the project folder and run sudo pod update, it should give you an output "Pod installation complete! There is 1 dependency from the Podfile and 1 total pod installed". After this restart your xcode file. Oh yeah and the last make sure you are opening .xcworkspace instead of xcodeproj
Reinstall Alamofire manually, and restart Xcode.
Make sure you check "No" on the project file for ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES
It took ages for me to get it to work.
I just created new Framework and added Firebase via CocoaPods, when combine the library it success.
But when I add that library to other project via CocoaPods as well, then combine that project, and it raise an error: No such module 'Firebase'
Anyone faced a problem like this?
You need to add the follwing to your POD file:
pod 'Firebase'
After that, you need to type in your terminal
pod install (to refresh the pod file)
I solve my problem using just the specific import that I'm using, for example.
In my SDK I'm using FirebaseCore and FirebaseAnalytics.
Into my class I just import:
import FirebaseCore
import FirebaseAnalytics
And in my .podspec I needed to set static_framework property to true, so my .podspec it's seems like code below:
s.static_framework = true
s.dependency 'Firebase'
s.dependency 'Firebase/Core'
It works for me!
Do you open the workspace file after installed with cocoa pods ?
Check if the library is added in "Linked Frameworks" or "Embedded Binaries"
If it didn't work, add this pod file
platform :ios, '8.0' use_frameworks! target ‘Your Project’ do
pod 'Firebase', '>= 2.5.1'
pod ‘Firebase/Auth’
pod ‘Google/SignIn’
pod ‘Firebase/Database’
pod 'Firebase/Storage' end
and then type pod deintegrate and after that run pod install.
tried all these..
I was stuck in this situation for more than 2weeks.
finally resolved by adding "excluded architectures = arm64"
this is the easiest solution nowadays
Everything was setup fine and was working before but..
My Problem:
What's was wrong with me?
I was using older name of pod, eg. - pod 'Firebase/Analytics', pod 'Firebase/Crashlytics'
New pod names are pod 'FirebaseAnalytics', pod 'FirebaseCrashlytics' (Problem with / )
Solution:
Use new pod name to integrate pod 'FirebaseAnalytics', pod 'FirebaseCrashlytics' (Install pod with new pod name)
Import import FirebaseCore, import FirebaseAnalytics instead just import Firebase
import FirebaseAnalytics - I'm using for log events
Hi today i fix same problem
1 : open podfile from xcode than add " pod 'Firebase' "
save and close it
2 : open vscode or any editor using, open new terminal than write " cd ios " to open ios file than " pod install " when you install it showing problem need to add search path
so now open ios file from xcode and go to : runner > target runner > build settings > all > search paths
and add this " $(inherited) " into framework search path and header search path
that's all
For me I had to change the version specified in the Podfile as it was above what my app supported. Specifically in the Podfile I changed: 'platform :ios, '11.0' to platform :ios, '10.0' which corresponds with Deployment Info in the General Tab for my app I'm working on.
For Flutter folks adding Firebase to their apps, make sure you follow the steps in Add Firebase to your iOS Project as well as those in the SDK setup steps in the Firebase Console:
In summary:
Run pod init if you don't have a pod file
Add the necessary pods to the bottom of the podfile. All possible Firebase pods can be found here.
pod 'Firebase/Analytics'
pod 'Firebase/Firestore'
pod 'Firebase/Auth'
pod 'Firebase/Storage'
Run pod install
This issue can be caused by incorrectly set-up schemes:
If you have multiple schemes (e.g. 'Dev', 'QA', 'Production' etc.) in your project, check you have the build configurations set correctly.
Further guidance in this answer here:
https://stackoverflow.com/a/65453578/12322900
Then run pod deintegrate and pod install and make sure you're using the .xcworkspace file.
My failure was that I downloaded modules to
target 'YourProjectUITests' do
# Pods for testing
pod 'FirebaseCore'
And the right one is
# Pods for YourProject
pod 'FirebaseCore'
(Without UITests)
It is because you don't have added pod dependency in Podfile.
you will find below line in Podfile
Uncomment this line to define a global platform for your project
#platform :ios, '9.0'
follow the below steps.
1)just remove the # .so it will be like.
platform :ios, '9.0'
2)add the below dependencies.(Do not add all ,you just need to add whatever used in you app ,if you have used Firebase/Core only then add that line only)
#Pods for app name
pod 'Firebase'
pod 'Firebase/Core'
pod 'Firebase/Auth'
pod 'Firebase/Database'
3)clean the build
flutter clean
4)run Command :
flutter run (It will automatically adds a required pods).
that's it.
The same thing happened to me last week. I solved it by:
1. pod deintegrate
2. Open Xcode and delete any instance of pod.
3. pod install
I've recently updated my Xcode, but I faced with strange issue.
I'm installing library via cocoapods and use it further in my project, but after updating I Xcode can't find the module, I've installed via CocoaPods
I've updating pods, but the problem stays.
Also I have Pods.framework red
What is the problem?
Podfile:
# Uncomment this line to define a global platform for your project
platform :ios, '9.0'
target 'Bloom' do
# Comment this line if you're not using Swift and don't want to use dynamic frameworks
use_frameworks!
# Pods for Bloom
target 'BloomTests' do
inherit! :search_paths
# Pods for testing
end
target 'BloomUITests' do
inherit! :search_paths
# Pods for testing
end
end
pod 'Firebase/Core'
pod 'Firebase/Database'
pod 'Firebase/Auth'
pod 'Gifu'
UPD: Solved it by opening the project with the .xcworkspace file not with .xcodeproj.
Do the following things and you can import any swift file from "Pods"
Clean your project
Make sure that all your "Pods" > "Build Settings" > "Build Active Architecture Only" is set to "NO".
Don't run, just build your project.
Now, import any file from "Pods" to any swift file
This will solve your import module problem.
Update:
To solve this issue delete the current pod file and create one using the terminal. Follow the below steps:
1) Open Terminal.
2) Navigate to your Project Path.
3) Type pod init in terminal to create new pod file.
4) Open the newly created pod file and write the pod line which you want to install after target "TargetName" do and before end.
5) Then type pod install in the terminal.
Hope this helps!
I had to delete my podfile and ALL the files it made including the .workspace file then I did:
pod init
open -a Xcode Podfile
add pods I want to podfile then save and close xcode.
Finally do pod install and open the new workspace file :)
change your pod file like this and clean the project quit xcode and reopen it.it may solve the problem
# Uncomment this line to define a global platform for your project
platform :ios, '9.0'
# Comment this line if you're not using Swift and don't want to use
dynamic frameworks
use_frameworks!
target 'Bloom' do
pod 'Firebase/Core'
pod 'Firebase/Database'
pod 'Firebase/Auth'
pod 'Gifu'
end
target 'BloomTests' do
inherit! :search_paths
# Pods for testing
end
target 'BloomUITests' do
inherit! :search_paths
# Pods for testing
end
Some frameworks in cocoapods declare a hard-link to XCode in the module description file (XMPP for example). So, be sure that you have:
place XCode.app in /Application (default folder), with name
"XCode.app", not Xcode-beta.app
or/and
call xcode-select to specify the right XCode.app:
sudo xcode-select --switch /Applications/Xcode.app
I had the same issue after I tried to merge a branch using Xcode (never again!).
What finally worked for me was:
Deleting derved data
Cleaning project
Exiting Xcode
Running 'pod install' again in my project
So I'm fairly new at both Swift and working with cocoapods, and after spending several days of researching I cannot figure out why my project isn't building. I get the following error:
(My project)/Pods/Target Support Files/Pods-(My project)/Pods-(My project)-frameworks.sh: No such file or directory
I am using Xcode 7.2.1 and Cocoapods 0.39.0 and I seem to have tried all the troubleshooting tips from Cocoapods' website. Can anyone tell me what I need to do to make it work?
My podfile:
source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '8.1'
use_frameworks!
pod 'GoogleMaps'
pod 'FontAwesome.swift'
pod 'Lock', '~> 1.21'
pod 'JWTDecode', '~> 1.0'
pod 'Lock-Facebook', '~> 2.1'
pod 'SimpleKeychain', '~> 0.7'
pod 'Bolts', '~> 1.6'
pod 'FBSDKCoreKit', '~> 4.1'
pod 'FBSDKLoginKit', '~> 4.1'
pod 'MBProgressHUD', '~> 0.9.2'
pod 'Alamofire', '~> 2.0'
pod 'CocoaLumberjack/Swift'
pod 'AFNetworking', '~> 2.5'
pod 'Auth0', '~> 0.2'
You're probably missing the target block for your target, in the Podfile.
I added a target to my project, and forgot to add a target block to the Podfile for that target, and I had the same error.
(My project)/Pods/Target Support Files/Pods-(My project)/Pods-(My project)-frameworks.sh: No such file or directory
The path components are actually named after the target:
(My project)/Pods/Target Support Files/Pods-[target]/Pods-[target]-frameworks.sh
Cocoapods builds configuration files for each target that you specify. Try adding a target entry to your Podfile, like so:
target "SOME TARGET" do
specify pods here
end
If you end up adding a lot of targets, it might be a good idea to define pod groups that you can easily use inside your target entries. So, you would define your groups above your target entries, like so:
def commonPods
specify pods here
end
Then you can use the group name in your pod entry, instead of copying all the pod entries for every target:
target "SOME TARGET" do
commonPods
end
Adding the target entry in your Podfile will cause CocoaPods to generate a new set of files the next time you run pod install. However, before you run that command, you will probably need to set your configurations to None, so that Cocoapods can assign its own configuration. Here's how to do that:
Go to your project-level target
For each configuration listed under Configurations, select None for your target, in the drop-down menu under Based on Configuration File.
These steps will eliminate the Cocoapods warning that reads:
CocoaPods did not set the base configuration of your project because your project already has a custom config set. In order for CocoaPods integration to work at all...
Once you've edited your Podfile and you nullified your configurations, you're ready to run pod install on the command line. After the process is completed, check back with your base configuration settings, and note that they have been set to the configuration file that was generated by CocoaPods!
I hope that helps!
This is kind of dumb, but it happened to me:
You might be in the wrong directory.
I was running pod install from directory Desktop/Project/Project Files, and I kept getting an error like this.
Then I realized I was in one step too far, so I went up to directory Desktop/Project, and it worked.
As to why pod install even ran considering the Podfile was in Desktop/Project and not Desktop/Project/Project Files... ¯\_(ツ)_/¯
My problem is that " blablabla Pods-XXXX-frameworks.sh: No such file or directory"
Firstly, I fix it by using command line "pod install" , it has nothing effection.
The finally solution :
Touch "Build Phases" -> "Embed Pods Frameworks" ,you can see the path :XXXXX.sh"
Be sure that the XXX.sh is the same as your project's. if not, change the path.
Then clean and build.
It's done.
Make sure that you are running pod install in the same directory where you have your xcode project.