module Trooper::DSL::Bundler

Public Instance Methods

bundle_exec(command) click to toggle source
# File lib/trooper/dsl/bundler.rb, line 5
def bundle_exec(command)
  use_bundle = using_bundler? ? "#{ruby_bin_path}bundle exec " : ""
  run use_bundle + command
end
bundle_install() click to toggle source
# File lib/trooper/dsl/bundler.rb, line 10
def bundle_install
  run "#{ruby_bin_path}bundle install --path #{trooper_path}/bundle --deployment --without development test" if using_bundler?
end
rake(command) click to toggle source
# File lib/trooper/dsl/bundler.rb, line 14
def rake(command)
  bundle_exec "rake #{command}"
end

Private Instance Methods

ruby_bin_path() click to toggle source
# File lib/trooper/dsl/bundler.rb, line 24
def ruby_bin_path
  config[:ruby_bin_path] || ""
end
using_bundler?() click to toggle source
# File lib/trooper/dsl/bundler.rb, line 20
def using_bundler?
  File.exists? "Gemfile"
end