Commit fb40cfbd719ccba86c37d13389b8a9b2407ef32a
1 parent
a231b1b9
Exists in
master
and in
29 other branches
Fix dangling symlink vendor/rails if necessary
Showing
1 changed file
with
1 additions
and
0 deletions
Show diff stats
config/boot.rb
... | ... | @@ -110,6 +110,7 @@ def install_debian_rails |
110 | 110 | local_rails = File.dirname(__FILE__) + '/../vendor/rails' |
111 | 111 | debian_rails = ['/usr/share/rails-ruby1.8', '/usr/lib/ruby/vendor_ruby/rails'].find { |d| File.exists?(d) } |
112 | 112 | if !File.exist?(local_rails) && File.exists?(debian_rails) |
113 | + File.delete(local_rails) if File.symlink?(local_rails) # remove dangling symlink | |
113 | 114 | puts "I: Installing Debian-installed Rails from /usr/share/rails into vendor/rails." |
114 | 115 | recommended_rails_version = Rails::GemBoot.gem_version |
115 | 116 | puts "I: Please note that the recommended Rails version is #{recommended_rails_version}, and that other versions might not work" | ... | ... |