cocoapods

How to use Google Analytics for iOS via cocoapods

隐身守侯 提交于 2019-11-29 10:38:38
In my bridging header, I infinitely get "<Google/Analytics.h> not found" I followed Google's own tutorial: https://developers.google.com/analytics/devguides/collection/ios/v3/?ver=swift I've tried the 'pod GoogleAnalytics' methods people have posted. I've tried all of the suggestions people have posted in other threads. Is there something else I need to change in the "build settings" ... or does 'pod install' do everything? Bridging Header: Build Settings: Podfile: Swift 4.0 and xcode 9.0.1 finally I resolved. For me after 2 days I resolved.. Don't follow Google's old documentation says

Upgrading Firebase broke my iOS project

我们两清 提交于 2019-11-29 10:32:31
I wish I had never updated my pod, the entire project was full of errors, one specific error is in the photo below, I can't fix it and I was ready to submit my app to the App Store now it seems like its all ruined. On top of this, it made me erase a bunch of optionals. func uploadData(user: User) { let changeRequest = user.createProfileChangeRequest() changeRequest.displayName = self.nameUser.text! changeRequest.commitChanges(completion: nil) let imageRef = self.userStorage.child("\(user.uid).jpg") let data = UIImageJPEGRepresentation(self.imageView.image!, 0.5) let uploadTask = imageRef.put

Can't get to work CocoaPods and Yosemite

淺唱寂寞╮ 提交于 2019-11-29 10:26:33
I already tried this steps: Open Xcode 6 Open Preferences Click the Locations tab Change the Command Line Tools version to Xcode 6.0 Uninstall cocoapods a. $sudo gem uninstall cocoapods Install xcodeproj a. $ sudo gem install xcodeproj Install cocoapods a. $ sudo gem install cocoapods Run pod --version to verify that it worked But I'm still gettings this when I do pod install or pod --version: /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require': cannot load such file -- xcodeproj/prebuilt/universal.x86_64-darwin14-2.0.0

GoogleAnalytics-iOS-SDK on CocoaPods 0.36 with Swift

孤者浪人 提交于 2019-11-29 10:04:11
Anyone knows How do I write Bridging Header for Swift with CocoaPods 0.36? I tried these ways. (1) #import <GoogleAnalytics-iOS-SDK/GAI.h> => this is cocoapods 0.35 style. failed to compile. (2) #import <GoogleAnalytics-iOS-SDK/GoogleAnalytics-iOS-SDK/GAI.h> => failed to compile. (3) #import "../Pods/GoogleAnalytics-iOS-SDK/GoogleAnalytics/Library/GAI.h" => it can be complied. but failed linking. I managed to successfully include Google Analytics iOS SDK 3.10 via Cocoapods into my Swift project using frameworks following these steps. On the Podfile add (note the use_frameworks! ): source

Why am I getting an undeclared type 'PubNub' compiler error with Swift Cocoa App and bridging header?

二次信任 提交于 2019-11-29 09:27:53
I am starting a new Cocoa Swift Project that is incorporating the PubNub SDK via CocoaPods with the following Podfile: target 'myProject' do source 'https://github.com/CocoaPods/Specs.git' use_frameworks! pod 'PubNub', '~>4.0' pod 'Alamofire', '~> 1.3' end target 'myProjectTests' do end In my auto-generated bridging header I have the import for PubNub as: #import <PubNub/PubNub.h> And my AppDelegate.swift file: import Cocoa @NSApplicationMain class AppDelegate: NSObject, NSApplicationDelegate { var client:PubNub? func applicationDidFinishLaunching(aNotification: NSNotification) { let config =

组件化pod库制作

时光毁灭记忆、已成空白 提交于 2019-11-29 08:54:30
一)、组件化的目的: 1、解耦各模块和业务,便于开发维护 2、构建可复用模块,便于复用 3、由于开发人员很多时,合作开发代码很容易冲突等,沟通成本很高,让各模块做成组件,每个人只负责某一模块,让开发更有效率 4、提高工程编译速度,当工程很大时,编译是一个十分耗时的过程,各模块做成组件,前期做功能时,只需关注编译自己的模块工程,减少总的编译时间 5、便于模块化测试,可以单独测试各组件模块 二)、组件化的类型:公有和私有podspec 1、使用Cocoapods创建公有podspec 2、使用Cocoapods创建私有podspec 三)、公有podspec制作步骤: 当然你电脑安装了cocoaPods了, 1、注册trunk 查看自己是否注册过trunk $pod trunk me 注册trunk $ pod trunk register 邮箱 ‘你的名称’ —description=‘电脑机型描述’ 如:$ pod trunk register zhangsan @163.com ‘zhangsan’ —description=‘MacBook Pro’ 注册后,cocoapods官方会向你邮箱发送确认邮件,点击确认即可. 确认后,可以再使用 $pod trunk me 查看个人信息 2、创建项目工程,并上传到github上,获得项目代码地址 https://github.com

How to use Cocoapods in a Swift framework?

你说的曾经没有我的故事 提交于 2019-11-29 08:24:13
问题 I am trying to create a new Cocoa Touch Framework for iOS in Swift, using some libraries from Cocoapods, but I can't have it work. I know there are some opened questions about that, but none of them seem to fix my problem. For testing purposes, I just created an empty Cocoa Touch Framework, installed Cocoapods and added the 'MBProgressHUD' pod. Then, as documented by Apple ('Importing Code from Within the Same Framework Target' section), I imported the MBProgressHUD header in my umbrella

Podfile: Path of local pod relative to Projectpath possible?

假装没事ソ 提交于 2019-11-29 07:51:01
问题 I am trying to add local pods to my objective c iOS project. Is there a way to use the rootpath of my project as relative path? The only way I got it to work is by using something like this: pod 'ObjCPod', :path => '~/Documents/iOS-Projects/MyApp/libraries/LocalPod/' This wouldn't work if I moved the Project folder or tried to build the project on another machine. I would like to have something like this: pod 'ObjCPod', :path => '$(SRCROOT)/libraries/LocalPod/' Is there a way to do that? 回答1:

Using SwiftyJSON with Swift3

时光毁灭记忆、已成空白 提交于 2019-11-29 07:05:37
问题 How do I use SwiftyJSON with Swift3? I've installed the pod. pod 'SwiftyJSON', :git => 'https://github.com/SwiftyJSON/SwiftyJSON.git', :branch => 'swift3' But it throws a lot of errors using Xcode 8 GM. Can someone help me install it properly? 回答1: SwiftyJSON now supports Swift 3. pod 'SwiftyJSON', '3.0.0' 回答2: Update: as Marcus notes, SwiftyJSON now supports Swift 3. In order to get bug fixes, I recommend not pinning yourself to 3.0.0, but rather: pod 'SwiftyJSON', '>= 3.0.0' …or if you don

Cocoa Pods Error ld: library not found for -lPods

假装没事ソ 提交于 2019-11-29 07:01:43
I'm getting a error from cocoa pods that I've never seen before. I've had it working with several dependencies just fine. I recently added the TestFlightSDK as a dependency through pods and I'm unable to Archive the project. It builds just fine to devices but refuses to Archive. Has anyone else experienced this issue? ld: library not found for -lPods clang: error: linker command failed with exit code 1 (use -v to see invocation) My Library Search Paths looks like this (for both debug and release): $(SRCROOT) recursive $(PODS_ROOT) recursive $(inherited) recursive anders Ok so I found the