Sha256: 8088b447e6ae214cc5159089a738867a0d2f9834ee34c184bcbaebd9e1044d7c

Contents?: true

Size: 892 Bytes

Versions: 1

Compression:

Stored size: 892 Bytes

Contents

require 'git_commands/command'

namespace :git_commands do
  desc <<END
Setup the command instance:
  > rake git_utils:setup repo=git_repository base_dir=repo_path branches_file=file_listing_branches branches=list,of,branches,separated,by,comma
END
  task :setup do
    @command = GitCommands::Command::new(:repo => ENV['repo'], 
                                      :base_dir => ENV['base_dir'], 
                                      :branches_file => ENV['branches_file'], 
                                      :branches => ENV['branches'])
  end
  
  desc 'Purge specified branches locally and from origin'
  task :purge => :setup do
    @command.purge
  end
  
  desc 'Rebase specified branches with master'
  task :rebase => :setup do
    @command.rebase
  end
  
  desc 'Aggregate specified branches into a single one'
  task :aggregate => :setup do
    @command.aggregate
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
git_commands-2.1.0 lib/tasks/git_commands.rake