diff options
Diffstat (limited to 'lib/bundler/cli/check.rb')
-rw-r--r-- | lib/bundler/cli/check.rb | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/lib/bundler/cli/check.rb b/lib/bundler/cli/check.rb index 057a7e5695..e572787dc4 100644 --- a/lib/bundler/cli/check.rb +++ b/lib/bundler/cli/check.rb @@ -1,4 +1,5 @@ # frozen_string_literal: true + module Bundler class CLI::Check attr_reader :options @@ -8,10 +9,7 @@ module Bundler end def run - if options[:path] - Bundler.settings[:path] = File.expand_path(options[:path]) - Bundler.settings[:disable_shared_gems] = true - end + Bundler.settings.set_command_option_if_given :path, options[:path] begin definition = Bundler.definition @@ -28,7 +26,7 @@ module Bundler not_installed.each {|s| Bundler.ui.error " * #{s.name} (#{s.version})" } Bundler.ui.warn "Install missing gems with `bundle install`" exit 1 - elsif !Bundler.default_lockfile.file? && Bundler.settings[:frozen] + elsif !Bundler.default_lockfile.file? && Bundler.frozen? Bundler.ui.error "This bundle has been frozen, but there is no #{Bundler.default_lockfile.relative_path_from(SharedHelpers.pwd)} present" exit 1 else |