lib/alfa/commands/new.rb in alfa-0.0.5.pre vs lib/alfa/commands/new.rb in alfa-0.0.6.pre

- old
+ new

@@ -1,14 +1,17 @@ require File.expand_path('../../../../version', __FILE__) require 'fileutils' require 'alfa/support' +require 'securerandom' PROJECT_NAME = $*[1] +SESSION_SECRET = SecureRandom.base64(24) sr = { '#{ALFA_VERSION}' => ALFA_VERSION, '#{PROJECT_NAME}' => PROJECT_NAME, + '#{SESSION_SECRET}' => SESSION_SECRET } target_dir = File.join(Dir.pwd, PROJECT_NAME) raise "file or directory #{PROJECT_NAME} already exists" if File.exists?(target_dir) Dir.mkdir PROJECT_NAME @@ -36,14 +39,16 @@ print "done" ensure puts "" end -begin - print "Bundle install... " - FileUtils.cd PROJECT_NAME - `bundle install` - print "done" -ensure - FileUtils.cd '..' - puts "" -end +puts "Run 'cd #{PROJECT_NAME} && bundle install' manually" + +# begin +# print "Bundle install... " +# FileUtils.cd PROJECT_NAME +# `bundle install` +# print "done" +# ensure +# FileUtils.cd '..' +# puts "" +# end