Sha256: 0925b7d384038d1e09df6c40aff8a897fe3e75f542fa129427cede02d244e25e

Contents?: true

Size: 1.06 KB

Versions: 16

Compression:

Stored size: 1.06 KB

Contents

Capistrano::Configuration.instance(:must_exist).load do
  after 'deploy:update_code', 'deploy:bundle:build'

  namespace :deploy do
    namespace :bundle do
      desc 'Bundles the gems into the repo'
      task :build, :except => { :no_release => true } do
        puts "\n\n### BUNDLE GEMS: Bundling up gems into vendor/bundle\n\n"
        args = ["--deployment"]
        args << "--without #{bundle_without.join(" ")}" unless bundle_without.empty?
        run "cd #{deploy_to} && sudo -u #{sudo_user} #{ruby_bin_dir}/bundle install #{args.join(' ')}"
      end

      desc 'Wipes out and rebundles the gems into the repo'
      task :rebuild, :except => { :no_release => true } do
        puts "\n\n### REBUILDING BUNDLE!: Wiping the existing bundle and rebuilding from scratch...\n\n"
        run "sudo rm -rf #{deploy_to}/vendor/bundle"
        args = ["--deployment"]
        args << "--without #{bundle_without.join(" ")}" unless bundle_without.empty?
        run "cd #{deploy_to} && sudo -u #{sudo_user} #{ruby_bin_dir}/bundle install #{args.join(' ')}"
      end
    end
  end
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
capistrano-git-plugins-0.0.18 lib/capistrano/git/plugins/bundler.rb
capistrano-git-plugins-0.0.17 lib/capistrano/git/plugins/bundler.rb
capistrano-git-plugins-0.0.16 lib/capistrano/git/plugins/bundler.rb
capistrano-git-plugins-0.0.15 lib/capistrano/git/plugins/bundler.rb
capistrano-git-plugins-0.0.14 lib/capistrano/git/plugins/bundler.rb
capistrano-git-plugins-0.0.13 lib/capistrano/git/plugins/bundler.rb
capistrano-git-plugins-0.0.12 lib/capistrano/git/plugins/bundler.rb
capistrano-git-plugins-0.0.11 lib/capistrano/git/plugins/bundler.rb
capistrano-git-plugins-0.0.10 lib/capistrano/git/plugins/bundler.rb
capistrano-git-plugins-0.0.9 lib/capistrano/git/plugins/bundler.rb
capistrano-git-plugins-0.0.8 lib/capistrano/git/plugins/bundler.rb
capistrano-git-plugins-0.0.7 lib/capistrano/git/plugins/bundler.rb
capistrano-git-plugins-0.0.6 lib/capistrano/git/plugins/bundler.rb
capistrano-git-plugins-0.0.5 lib/capistrano/git/plugins/bundler.rb
capistrano-git-plugins-0.0.3 lib/capistrano/git/plugins/bundler.rb
capistrano-git-plugins-0.0.2 lib/capistrano/git/plugins/bundler.rb