summaryrefslogtreecommitdiff
path: root/lib/bundler/cli/info.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/bundler/cli/info.rb')
-rw-r--r--lib/bundler/cli/info.rb9
1 files changed, 6 insertions, 3 deletions
diff --git a/lib/bundler/cli/info.rb b/lib/bundler/cli/info.rb
index c79c8bf814..7f4ef0d03a 100644
--- a/lib/bundler/cli/info.rb
+++ b/lib/bundler/cli/info.rb
@@ -40,10 +40,13 @@ module Bundler
end
def print_gem_path(spec)
- path = if spec.name == "bundler"
- File.expand_path("../../../..", __FILE__)
+ if spec.name == "bundler"
+ path = File.expand_path("../../../..", __FILE__)
else
- spec.full_gem_path
+ path = spec.full_gem_path
+ unless File.directory?(path)
+ return Bundler.ui.warn "The gem #{gem_name} has been deleted. It was installed at: #{path}"
+ end
end
Bundler.ui.info path