4

I'm setting up CI for a project using CocoaPods. I set up Xcode server locally on my Mac. Pod directory is not under source control, so put

pod install

in my 'Before Integration' script for my Bot, and got 'pod: command not found' error.

I certainly have pods installed on my machine, how do I make it visible for the server?

Braiam
  • 1
  • 11
  • 47
  • 78
keith
  • 228
  • 2
  • 8

2 Answers2

7

you can also use this line in the beginning of your trigger and you can run all other commands without using /usr/local/bin

export PATH=$PATH:/usr/local/bin

But i would recommend to commit your Pods into the repository, so the CI does not have to care about it.

Alex
  • 156
  • 4
1

It's possible that your CI service can't resolve the pod symlink. I had a similar problem on a past Jenkins machine. Run which pod to find the path to the pod binary, and call the binary directly from your CI service:

➜  ~ which pod
/usr/local/bin/pod

In your script:

/usr/local/bin/pod install
JAL
  • 41,701
  • 23
  • 172
  • 300