2016-02-03 78 views
1

.travis.yml文件:与特拉维斯-CI错误 “EVAL吊舱安装”

language: objective-c 

script: 
    xctool -workspace ProjectName.xcworkspace -scheme ProjectName build -sdk iphonesimulator 

虽然特拉维斯-CI正在建设它说该项目:

$ bundle --version 
Bundler version 1.7.4 
$ xcodebuild -version -sdk 
$ pod --version 
0.34.4 
Installing Pods with 'pod install' 
$ pushd . 
~/build/GabrielMassana/ProjectName-iOS 
$ pod install 

在安装吊舱的错误是:

The command "eval pod install" failed. Retrying, 2 of 3. 
The command "eval pod install" failed. Retrying, 3 of 3. 
The command "eval pod install" failed 3 times. 
The command "pod install" failed and exited with 1 during . 
Your build has been stopped. 

回答

3

我发现添加这行代码解决了我的问题。

before_install: 
    - rvm use system 
    - sudo gem install cocoapods -v '0.39.0' 

所以我最后.travis.yml文件:

language: objective-c 

before_install: 
    - rvm use system 
    - sudo gem install cocoapods -v '0.39.0' 

script: 
    xctool -workspace ProjectName.xcworkspace -scheme ProjectName build -sdk iphonesimulator 

现在的CocoaPods完成安装。

也许有些特拉维斯机设置为与旧版本(0.34.4)

I also wrote a post in my blog about Travis-CI.

运行