diff options
author | Andre Arko <andre@arko.net> | 2014-10-20 00:06:40 -0700 |
---|---|---|
committer | Andre Arko <andre@arko.net> | 2014-10-20 00:37:14 -0700 |
commit | ca0676cb1c638e0b9747ea8c18f28adf82cc01de (patch) | |
tree | 93dc1ba866378b05d5bd0ea1667536eef22d7ca1 /lib/bundler | |
parent | fc273b9b192a29037a4edeb6cad1e1140c857af6 (diff) | |
download | bundler-ca0676cb1c638e0b9747ea8c18f28adf82cc01de.tar.gz |
hide all warnings when in --quiet mode
fixes #3186
Diffstat (limited to 'lib/bundler')
-rw-r--r-- | lib/bundler/cli/install.rb | 3 | ||||
-rw-r--r-- | lib/bundler/cli/package.rb | 4 | ||||
-rw-r--r-- | lib/bundler/cli/update.rb | 2 |
3 files changed, 6 insertions, 3 deletions
diff --git a/lib/bundler/cli/install.rb b/lib/bundler/cli/install.rb index 9bb7f681..80f9fd50 100644 --- a/lib/bundler/cli/install.rb +++ b/lib/bundler/cli/install.rb @@ -6,6 +6,8 @@ module Bundler end def run + Bundler.ui.level = "error" if options[:quiet] + warn_if_root if options[:without] @@ -66,7 +68,6 @@ module Bundler Bundler.settings[:no_prune] = true if options["no-prune"] Bundler.settings[:clean] = options["clean"] if options["clean"] Bundler.settings.without = options[:without] - Bundler.ui.level = "warn" if options[:quiet] Bundler::Fetcher.disable_endpoint = options["full-index"] Bundler.settings[:disable_shared_gems] = Bundler.settings[:path] ? '1' : nil diff --git a/lib/bundler/cli/package.rb b/lib/bundler/cli/package.rb index b2946038..5adad44c 100644 --- a/lib/bundler/cli/package.rb +++ b/lib/bundler/cli/package.rb @@ -7,10 +7,12 @@ module Bundler end def run - Bundler.ui.level = "warn" if options[:quiet] + Bundler.ui.level = "error" if options[:quiet] Bundler.settings[:path] = File.expand_path(options[:path]) if options[:path] + setup_cache_all install + # TODO: move cache contents here now that all bundles are locked custom_path = Pathname.new(options[:path]) if options[:path] Bundler.load.cache(custom_path) diff --git a/lib/bundler/cli/update.rb b/lib/bundler/cli/update.rb index 920221f7..dd15de99 100644 --- a/lib/bundler/cli/update.rb +++ b/lib/bundler/cli/update.rb @@ -7,10 +7,10 @@ module Bundler end def run + Bundler.ui.level = "error" if options[:quiet] sources = Array(options[:source]) groups = Array(options[:group]).map(&:to_sym) - Bundler.ui.level = "warn" if options[:quiet] if gems.empty? && sources.empty? && groups.empty? # We're doing a full update |