2013-08-07 84 views
0

twitter.gemspec文件降解Gem依賴

# coding: utf-8 
lib = File.expand_path('../lib', __FILE__) 
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib) 
require 'twitter/version' 

Gem::Specification.new do |spec| 
    spec.add_dependency 'faraday', ['~> 0.8', '< 0.10'] 
    spec.add_dependency 'multi_json', '~> 1.0' 
    spec.add_dependency 'simple_oauth', '~> 0.2' 
    spec.add_development_dependency 'bundler', '~> 1.0' 
    spec.authors = ["John Nunemaker", "Wynn Netherland", "Erik Michaels-Ober", "Steve Richert", "Steve Agalloco"] 
    spec.cert_chain = ['certs/sferik.pem'] 
    spec.description = %q{A Ruby interface to the Twitter API.} 
    spec.email = ['[email protected]', '[email protected]', '[email protected]', '[email protected]', '[email protected]'] 
    spec.files = %w(.yardopts CHANGELOG.md CONTRIBUTING.md LICENSE.md README.md Rakefile twitter.gemspec) 
    spec.files += Dir.glob("lib/**/*.rb") 
    spec.files += Dir.glob("spec/**/*") 
    spec.homepage = 'http://sferik.github.com/twitter/' 
    spec.licenses = ['MIT'] 
    spec.name = 'twitter' 
    spec.require_paths = ['lib'] 
    spec.required_rubygems_version = '>= 1.3.5' 
    #spec.signing_key = File.expand_path("~/.gem/private_key.pem") if $0 =~ /gem\z/ 
    spec.summary = spec.description 
    spec.test_files = Dir.glob("spec/**/*") 
    spec.version = Twitter::Version 
end 

我想降級的依賴性法拉第0.8至0.7我怎麼能做到這一點 plase幫我

回答

0

如果你只是想在最新的補丁0.7樹,你只需要改變法拉第行這樣的:

spec.add_dependency 'faraday', '~> 0.7.0' 

或者,如果你願意,你可以指定一個特定版本:

spec.add_dependency 'faraday', '0.7.1' 

對於我建議你閱讀有關Gemfiles所述捆綁頁的詳細信息http://bundler.io/v1.3/gemfile.html