I already have one project working with a podfile.
I wanted to add a Podfile on an old project but I got this error on sudo pod install
sudo pod install
Error:>
From the command line run rm -rf ~/.cocoapods
rm -rf ~/.cocoapods
Then run pod install again. You shouldn't need the sudo.
pod install
This look like it's caused because there was a change to a spec and it's conflicting with running a git pull
git pull