Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

make sure capistrano only tries to load Net::SSH and Net::SFTP versio…

…ns less than 1.99.0

git-svn-id: http://svn.rubyonrails.org/rails/tools/capistrano@8750 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
  • Loading branch information...
commit f0fbbec55afdd56a74d314d010f29a3966d8c2a7 1 parent 8e9d456
@jamis jamis authored
View
6 capistrano.gemspec
@@ -12,18 +12,18 @@ Gem::Specification.new do |s|
s.files = Dir.glob("{bin,lib,examples,test}/**/*") + %w(README MIT-LICENSE CHANGELOG)
s.require_path = 'lib'
- s.autorequire = 'capistrano'
s.has_rdoc = true
s.bindir = "bin"
s.executables << "cap" << "capify"
- s.add_dependency 'net-ssh', ">= #{Capistrano::Version::SSH_REQUIRED.join(".")}"
- s.add_dependency 'net-sftp', ">= #{Capistrano::Version::SFTP_REQUIRED.join(".")}"
+ s.add_dependency 'net-ssh', ">= #{Capistrano::Version::SSH_REQUIRED.join(".")}", "< 1.99.0"
+ s.add_dependency 'net-sftp', ">= #{Capistrano::Version::SFTP_REQUIRED.join(".")}", "< 1.99.0"
s.add_dependency 'highline'
s.author = "Jamis Buck"
s.email = "jamis@37signals.com"
s.homepage = "http://www.capify.org"
+ s.rubyforge_project = "capistrano"
end
View
6 lib/capistrano/ssh.rb
@@ -1,3 +1,9 @@
+begin
+ require 'rubygems'
+ gem 'net-ssh', "< 1.99.0"
+rescue LoadError, NameError
+end
+
require 'net/ssh'
module Capistrano
View
6 lib/capistrano/upload.rb
@@ -1,3 +1,9 @@
+begin
+ require 'rubygems'
+ gem 'net-sftp', "< 1.99.0"
+rescue LoadError, NameError
+end
+
require 'net/sftp'
require 'net/sftp/operations/errors'
require 'capistrano/errors'
Please sign in to comment.
Something went wrong with that request. Please try again.