I am trying to install the latest CocoaPods (which is 0.36.1) but it shows me the following error.
$ gem install cocoapods ERROR: Could not find a valid gem 'xcodeproj' (~> 0.23.1) in any repository Sudo?
Btw, in the answered questions some are proposed using sudo get install cocoapods. You do need sudo indeed if you are using the system-wide ruby executable. I am using rbenv for my ruby management, it is installed locally for the user and does not need sudo.
Update
The gem install cocoapods command worked the following day. Mystery.