Cocoapod Installation Use and FAQs

Source: Internet
Author: User
Tags i18n install cocoapods

1.cocoapod according to, Cocoapod is running in the ruby environment, in the ruby environment, such as cocoapod, such as open-source projects placed on the RubyGems server, but the domestic access https://rubygems.org/ Time will often appear timeout, China ZF you know, we need to remove the server address and add the mirror address provided by Taobao: http://ruby.taobao.org/

Remove command:gem sources--remove https://rubygems.org/

Add command:gem sources-a http://ruby.taobao.org/

View gem Source list : $ gem sources-l

installation cocoapod:sudo gem install cocoapods

navigate to the project with the Podsfile file directory, execute the command to install: pod Install

2. Frequently Asked Questions

1. Sometimes after the pod install, the Open Project compilation fails because the GIT project may have sub-modules that need to be updated recursively. You need to go to the Submodule directory to perform the update command: git submodule update--init--recursive

2. http://blog.csdn.net/ralbatr/article/details/39082937

Recently used Cocoapods to add a third-party class library, whether the pod install or pod update is stuck in the analyzing dependencies

The reason is that when executing the above two commands will upgrade the Cocoapods spec warehouse, add a parameter can omit this step, and then the speed will be improved a lot. The commands to add parameters are as follows:

Pod Install--verbose--no-repo-update

Pod Update--verbose--no-repo-update

-------------------------------------------------------------

Last Login:tue Oct 19:14:29 on console

chenyisis-mac-mini:~ chenyisi$

chenyisis-mac-mini:~ chenyisi$ RUBY-E

Ruby:no code specified FOR-E (runtimeerror)

chenyisis-mac-mini:~ chenyisi$ sudo gem install cocoapods

Password:

Sorry, try again.

Password:

Sorry, try again.

Password:

Error:could not find a valid gem ' cocoapods ' (>= 0), where is:

Unable to download data from https://rubygems.org/-errno::etimedout:operation timed Out-connect (2) (Https://rubygems. org/latest_specs.4.8.gz)

Gem Sources--remove https://rubygems.org/

chenyisis-mac-mini:~ chenyisi$ gem sources--remove https://rubygems.org/

Https://rubygems.org/removed from sources

chenyisis-mac-mini:~ chenyisi$ Gem sources-a http://ruby.taobao.org/

http://ruby.taobao.org/added to sources

chenyisis-mac-mini:~ chenyisi$ Gem sources-l

Current SOURCES * * *

http://ruby.taobao.org/

chenyisis-mac-mini:~ chenyisi$ sudo gem install cocoapods

Password:

Fetching:i18n-0.6.11.gem (100%)

Successfully installed i18n-0.6.11

Fetching:multi_json-1.10.1.gem (100%)

Successfully installed multi_json-1.10.1

Fetching:activesupport-3.2.19.gem (100%)

Successfully installed activesupport-3.2.19

Fetching:nap-0.8.0.gem (100%)

Successfully installed nap-0.8.0

Fetching:json_pure-1.8.1.gem (100%)

Successfully installed json_pure-1.8.1

Fetching:fuzzy_match-2.0.4.gem (100%)

Successfully installed fuzzy_match-2.0.4

Fetching:cocoapods-core-0.34.2.gem (100%)

Successfully installed cocoapods-core-0.34.2

Fetching:claide-0.7.0.gem (100%)

Successfully installed claide-0.7.0

Fetching:colored-1.2.gem (100%)

Successfully installed colored-1.2

Fetching:xcodeproj-0.19.3.gem (100%)

Successfully installed xcodeproj-0.19.3

Fetching:cocoapods-downloader-0.7.2.gem (100%)

Successfully installed cocoapods-downloader-0.7.2

Fetching:cocoapods-plugins-0.3.1.gem (100%)

Successfully installed cocoapods-plugins-0.3.1

Fetching:cocoapods-try-0.4.1.gem (100%)

Successfully installed cocoapods-try-0.4.1

Fetching:netrc-0.7.7.gem (100%)

Successfully installed netrc-0.7.7

Fetching:cocoapods-trunk-0.3.0.gem (100%)

Successfully installed cocoapods-trunk-0.3.0

Fetching:escape-0.0.4.gem (100%)

Successfully installed escape-0.0.4

Fetching:open4-1.3.4.gem (100%)

Successfully installed open4-1.3.4

Fetching:cocoapods-0.34.2.gem (100%)

Successfully installed cocoapods-0.34.2

Parsing documentation for I18N-0.6.11

Installing RI documentation for i18n-0.6.11

Parsing documentation for multi_json-1.10.1

Installing RI documentation for multi_json-1.10.1

Parsing documentation for ACTIVESUPPORT-3.2.19

Unable to convert "\x80" from Ascii-8bit to UTF-8 for Lib/active_support/values/unicode_tables.dat, skipping

Installing RI documentation for ACTIVESUPPORT-3.2.19

Parsing documentation for nap-0.8.0

Installing RI documentation for nap-0.8.0

Parsing documentation for json_pure-1.8.1

Installing RI documentation for json_pure-1.8.1

Parsing documentation for fuzzy_match-2.0.4

Installing RI documentation for fuzzy_match-2.0.4

Parsing documentation for cocoapods-core-0.34.2

Installing RI documentation for cocoapods-core-0.34.2

Parsing documentation for claide-0.7.0

Installing RI documentation for claide-0.7.0

Parsing documentation for colored-1.2

Installing RI documentation for colored-1.2

Parsing documentation for xcodeproj-0.19.3

Installing RI documentation for xcodeproj-0.19.3

Parsing documentation for cocoapods-downloader-0.7.2

Installing RI documentation for cocoapods-downloader-0.7.2

Parsing documentation for cocoapods-plugins-0.3.1

Installing RI documentation for cocoapods-plugins-0.3.1

Parsing documentation for cocoapods-try-0.4.1

Installing RI documentation for cocoapods-try-0.4.1

Parsing documentation for netrc-0.7.7

Installing RI documentation for netrc-0.7.7

Parsing documentation for COCOAPODS-TRUNK-0.3.0

Installing RI documentation for COCOAPODS-TRUNK-0.3.0

Parsing documentation for escape-0.0.4

Installing RI documentation for escape-0.0.4

Parsing documentation for open4-1.3.4

Installing RI documentation for open4-1.3.4

Parsing documentation for cocoapods-0.34.2

Installing RI documentation for cocoapods-0.34.2

Gems installed

chenyisis-mac-mini:~ chenyisi$ Cd/users/chenyisi/desktop/ios/swiftweather-master

Chenyisis-mac-mini:swiftweather-master chenyisi$ pod Install

Setting up CocoaPods master Repo

Setup completed

Analyzing dependencies

Downloading dependencies

Installing Afnetworking (2.3.1)

Generating Pods Project

Integrating client Project

[!] The use of implicit sources has been deprecated. To continue using any of the sources currently on your machine, add the following to the top of your podfile:

SOURCE ' Https://github.com/CocoaPods/Specs.git '

Chenyisis-mac-mini:swiftweather-master chenyisi$

Cocoapod Installation Use and FAQs

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.