"IOS" Installation CocoaPods

Source: Internet
Author: User

1. Open Terminal

2. Remove the existing Ruby default source

$ gem Sources--remove https://rubygems.org/

3. Use the new source

$ gem sources-a https://ruby.taobao.org/

4. Verify that the Xinyuan is replaced successfully

$ gem sources-l

After success appears:

Current SOURCES * *https://ruby.taobao.org/

5. Installing CocoaPods

sudo Install cocoapods$ pod Setup

Note: Apple system upgrade OS X EI Capitan after installation to ( I use the system, so the above command is not verified ):

sudo Install -n/usr/local/bin cocoapods$ pod setup

1) Following the successful execution of the first command, it will appear as follows:

2) After successful execution of the second command, the contents are as follows:

Note: You may need to wait a little longer.

6. Update the GEM

sudo gem update--system

If you enter:

Pod

command, a pod-related help command appears, indicating that the installation was successful!

To view the version number of the command:

Pod--version

Other operations:

1. Create a new Podfile file

Touch Podfile

2. Edit the Podfile file and write to the third-party library you want to add

' 8.0 '  'afnetworking'~> 2.3.1'<-------third party

3. Installing third-party libraries

Install

PS: More commands to open the terminal, use the pod command to view the help.

Reference:

1. CocoaPods Installation and use

2. Installation process for the latest version of IOS CocoaPods

"IOS" Installation CocoaPods

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.