summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSamuel Giddins <segiddins@segiddins.me>2017-12-01 11:23:55 -0600
committerSamuel Giddins <segiddins@segiddins.me>2017-12-01 11:23:55 -0600
commit830e95f2e11a2c619a6a195e355afb6c55894d59 (patch)
treed6b8ad03578fd398ecdb41c842dff3173921a321
parentfd585f469fdfca77d4f9637e84ccb6c9a0ed3266 (diff)
downloadbundler-colby/bundle-show-paths.tar.gz
[CLI::List] Raise when incompatible options are passedcolby/bundle-show-paths
-rw-r--r--lib/bundler/cli/list.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/bundler/cli/list.rb b/lib/bundler/cli/list.rb
index 47d512eb70..c92f05df07 100644
--- a/lib/bundler/cli/list.rb
+++ b/lib/bundler/cli/list.rb
@@ -9,7 +9,7 @@ module Bundler
def run
specs = Bundler.load.specs.reject {|s| s.name == "bundler" }.sort_by(&:name)
- return Bundler.ui.error "The `--name-only` and `--paths` options cannot be used together" if @options["name-only"] && @options["paths"]
+ raise InvalidOption, "The `--name-only` and `--paths` options cannot be used together" if @options["name-only"] && @options["paths"]
return specs.each {|s| Bundler.ui.info s.name } if @options["name-only"]
return specs.each {|s| Bundler.ui.info s.full_gem_path } if @options["paths"]