Sha256: 9dab12b9c718f0fe80e91c3852f2c3d5b7dc7e1b1ff8423a2944f44e301b862f
Contents?: true
Size: 991 Bytes
Versions: 5
Compression:
Stored size: 991 Bytes
Contents
require 'rgitflow/tasks/task' module RGitFlow module Tasks class Release class Finish < RGitFlow::Tasks::Task def initialize(git) super(git, 'finish', 'Finish a release branch', ['rgitflow', 'release']) end protected def run status 'Finishing release branch...' branch = @git.current_branch unless branch.start_with? RGitFlow::Config.options[:release] error 'Cannot finish a release branch unless you are in a release branch' abort end @git.branch(RGitFlow::Config.options[:master]).checkout @git.merge branch @git.push if @git.is_remote_branch? branch @git.push('origin', branch, {:delete => true}) end @git.branch(branch).delete @git.branch(RGitFlow::Config.options[:develop]).checkout status "Finished release branch #{branch}!" end end end end end
Version data entries
5 entries across 5 versions & 1 rubygems