降低Cocoapods的版本

为了兼容第三方库 需要降低Cocoapods的版本

所以需要执行那些命令呢?

相关操作,打开终端
一. 移除pod组件

这条指令会告诉你Cocoapods组件装在哪里 :
$ which pod
你可以手动移除这个组件 :
$ sudo rm -rf 

降低版本:
二. 移除 RubyGems 中的 Cocoapods程序包
RubyGems(简称 gems)是一个用于对 Ruby组件进行打包的 Ruby 打包系统。 它提供一个分发 Ruby 程序和库的标准格式,还提供一个管理程序包安装的工具。

查看gems中本地程序包
$ gem list
输出
*** LOCAL GEMS ***

activesupport (4.2.9)
addressable (2.5.1)
babosa (1.0.2)
bigdecimal (default: 1.3.0)
bundler (1.15.1)
bundler-unload (1.0.2)
CFPropertyList (2.3.5)
chunky_png (1.3.8)
claide (1.0.2)
cocoapods (1.2.1)
cocoapods-core (1.2.1)
cocoapods-deintegrate (1.0.1)
cocoapods-downloader (1.1.3)
cocoapods-plugins (1.0.0)
cocoapods-search (1.0.0)
cocoapods-stats (1.0.0)
cocoapods-trunk (1.2.0)
cocoapods-try (1.1.0)
colored (1.2)
colored2 (3.1.2)
commander-fastlane (4.4.5)
declarative (0.0.9)
declarative-option (0.1.0)
did_you_mean (1.1.0)
domain_name (0.5.20170404)
dotenv (2.2.1)
escape (0.0.4)
excon (0.57.1)
executable-hooks (1.3.2)
faraday (0.12.1)
faraday-cookie_jar (0.0.6)
faraday_middleware (0.11.0.1)
fastimage (2.1.0)
fastlane (2.45.0, 2.44.1)
fir-cli (1.6.3)
fourflusher (2.0.1)
fuzzy_match (2.0.4)
gem-wrappers (1.2.7)
gh_inspector (1.0.3)
google-api-client (0.12.0)
googleauth (0.5.1)
highline (1.7.8)
http-cookie (1.0.3)
httpclient (2.8.3)
i18n (0.8.4)
io-console (default: 0.4.6)
json (default: 2.0.2)
jwt (1.5.6)
little-plugger (1.1.4)
logging (2.2.2)
memoist (0.16.0)
mime-types (3.1)
mime-types-data (3.2016.0521)
mini_magick (4.5.1)
minitest (5.10.1)
molinillo (0.5.7)
multi_json (1.12.1)
multi_xml (0.6.0)
multipart-post (2.0.0)
nanaimo (0.2.3)
nap (1.1.0)
net-telnet (0.1.1)
netrc (0.11.0, 0.7.8)
openssl (default: 2.0.2)
os (0.9.6)
plist (3.3.0)
power_assert (0.4.1)
psych (default: 2.2.2)
public_suffix (2.0.5)
rake (12.0.0)
rdoc (default: 5.0.0)
representable (3.0.4)
rest-client (2.0.2)
retriable (3.0.2)
rouge (2.0.7)
rqrcode (0.10.1)
ruby-macho (1.1.0)
ruby_android (0.7.7)
rubygems-bundler (1.4.4)
rubyzip (1.2.1)
rvm (1.11.3.9)
security (0.1.3)
signet (0.7.3)
slack-notifier (1.5.1)
terminal-notifier (1.8.0)
terminal-table (1.8.0)
test-unit (3.2.3)
thor (0.19.4)
thread_safe (0.3.6)
tty-screen (0.5.0)
tzinfo (1.2.3)
uber (0.1.0)
unf (0.1.4)
unf_ext (0.0.7.4)
unicode-display_width (1.3.0)
word_wrap (1.0.0)
xcodeproj (1.5.0)
xcpretty (0.2.8)
xcpretty-travis-formatter (0.0.4)
xmlrpc (0.2.1)

移除cocoapods 想干程序包

$ sudo gem uninstall cocoapods -v 1.2.1
输出
Password:
Remove executables:
    pod, sandbox-pod

in addition to the gem? [Yn]  y
Removing pod
Removing sandbox-pod
Successfully uninstalled cocoapods-1.2.1
$ sudo gem uninstall cocoapods-core -v 1.2.1
输出
Successfully uninstalled cocoapods-core-0.35.0

然后安装指定版本的Cocoapods

$ sudo gem install cocoapods -v 1.1.1
安装成功后
$ pod --version
输出
1.1.1

你可能感兴趣的:(降低Cocoapods的版本)