gemfiles are required but lets still keep the convenience of bundling

This commit is contained in:
Karl Freeman 2014-03-13 09:46:49 +00:00
parent 323d8d769c
commit 9de092ba5f
2 changed files with 1 additions and 9 deletions

View file

@ -28,10 +28,6 @@ module Middleman::Cli
:type => :boolean, :type => :boolean,
:default => false, :default => false,
:desc => 'Include a config.ru file' :desc => 'Include a config.ru file'
method_option 'skip-gemfile',
:type => :boolean,
:default => false,
:desc => "Don't create a Gemfile"
method_option 'skip-bundle', method_option 'skip-bundle',
:type => :boolean, :type => :boolean,
:aliases => '-B', :aliases => '-B',

View file

@ -62,17 +62,13 @@ module Middleman
end end
class_option :'skip-bundle', :type => :boolean, :default => false class_option :'skip-bundle', :type => :boolean, :default => false
class_option :'skip-gemfile', :type => :boolean, :default => false
# Write a Bundler Gemfile file for project # Write a Bundler Gemfile file for project
# @return [void] # @return [void]
def generate_bundler! def generate_bundler!
return if options[:'skip-gemfile']
template self.class.gemfile_template, File.join(location, 'Gemfile')
return if options[:'skip-bundle'] return if options[:'skip-bundle']
inside(location) do inside(location) do
::Middleman::Cli::Bundle.new.invoke(:bundle) run('bundle install')
end unless ENV['TEST'] end unless ENV['TEST']
end end