title: Getting error in setting up Cocoa Pods and install update for Ruby
body: <p>I am trying to setup cocoapods to my iOS application But when I go for command:  </p>
  
  <pre><code>sudo gem update --system
  </code></pre>
  
  <p>I get error : Latest version currently installed. Aborting.</p>
  
  <p>When I go to next step for cocoapods:</p>
  
  <pre><code>sudo gem install cocoapods
  </code></pre>
  
  <p>I get error on Mac OS 10.8.5 :   </p>
  
  <pre><code>ERROR:  Error installing cocoapods:
  cocoapods-trunk requires Ruby version &gt;= 2.0.0. 
  </code></pre>
  
  <p>I tried same on Mac OS 10.9.4 and getting error :  </p>
  
  <pre><code>ERROR:  Could not find a valid gem 'cocoapods' (&gt;= 0), here is why:
        Unable to download data from https://rubygems.org/ - Errno::ECONNREFUSED: Connection refused - connect(2) (https://rubygems.org/latest_specs.4.8.gz)​
  </code></pre>