Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fail gracefully from svn checks (closes #2700) [Rick Olson]

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2907 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
  • Loading branch information...
commit 3c8d425bb23db54f82b1e9711428d42d3922287d 1 parent 01cfd2b
@dhh dhh authored
View
4 railties/lib/commands/plugin.rb
@@ -93,8 +93,8 @@ def install(name_uri_or_plugin)
end
def use_svn?
- `svn --version`
- $?.success?
+ `svn --version` rescue nil
+ !$?.nil? && $?.success?
end
def use_externals?
View
4 railties/lib/tasks/framework.rake
@@ -30,8 +30,8 @@ end
desc "Lock this application to the Edge Rails (by exporting from Subversion). Defaults to svn HEAD; do 'rake freeze_edge REVISION=1234' to lock to a specific revision."
task :freeze_edge do
$verbose = false
- `svn --version`
- unless $?.success?
+ `svn --version` rescue nil
+ unless !$?.nil? && $?.success?
$stderr.puts "ERROR: Must have subversion (svn) available in the PATH to lock this application to Edge Rails"
exit 1
end
Please sign in to comment.
Something went wrong with that request. Please try again.