Now I've got to do as follows:
require 'mina/multistage' # invokes stage file (e.g., config/deploy/production.rb), which sets rails_env
require 'mina/rails' # sets rails_env
invoke ARGV.first if fetch(:all_stages).include?(ARGV.first) # invoke stage file again to set rails_env again
puts fetch(:rails_env)
With set_default it could be this way:
require 'mina/multistage' # invokes stage file (e.g., config/deploy/production.rb)
require 'mina/rails' # set_default's rails_env
puts fetch(:rails_env)
Is there any reason not to add set_default? Or set rails_env this way:
set :rails_env, 'production' unless set?(:rails_env)
Now I've got to do as follows:
With
set_defaultit could be this way:Is there any reason not to add
set_default? Or setrails_envthis way: