Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Ignore Xcode warnings when using Cocoapods

I use quite a lot third party libraries which have many warnings in it, after the latest Xcode updates. (for example the Facebook SDK pod) Now all these warnings are shown in my Xcode on the place I want to see my own warnings or errors.

Is there any way to ignore these errors? Fixing them won't help, since after every "pod install" the changes are discarded.

like image 602
KrauseFx Avatar asked Nov 03 '12 10:11

KrauseFx


People also ask

How do I turn off warnings in Xcode?

If you want to disable all warnings, you can pass the -suppress-warnings flag (or turn on "Suppress Warnings" under "Swift Compiler - Warning Policies" in Xcode build settings).

Does CocoaPods require Xcode?

In order to use CocoaPods you need to define the Xcode target to link them to. So for example if you are writing an iOS app, it would be the name of your app.

Is CocoaPods safe?

Security vulnerability in CocoaPods dev tool could have affected millions of iOS apps. The security of millions of iOS apps could have been compromised due to a security vulnerability in the popular dependency manager CocoaPods.


2 Answers

You can search for "inhibit_all_warnings" in your Xcode build settings of the PodBundle in your project-workspace. Set the value to "YES" and it will hide all your Pod file warnings.

If you do it to your workspace it will hide all your project warnings also.

like image 22
Teja Swaroop Avatar answered Sep 20 '22 10:09

Teja Swaroop


Add to your Podfile:

platform :ios  # ignore all warnings from all pods inhibit_all_warnings!  # ignore warnings from a specific pod pod 'FBSDKCoreKit', :inhibit_warnings => true 

Then execute: pod install

like image 135
alloy Avatar answered Sep 18 '22 10:09

alloy