Class: Semmy::Tasks::Branches

Inherits:
Base
  • Object
show all
Defined in:
lib/semmy/tasks/branches.rb

Instance Attribute Summary

Attributes inherited from Base

#config

Instance Method Summary collapse

Methods inherited from Base

#initialize

Constructor Details

This class inherits a constructor from Semmy::Tasks::Base

Instance Method Details

#defineObject



6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
# File 'lib/semmy/tasks/branches.rb', line 6

def define
  namespace 'branches' do
    task 'create_stable' do
      name = config.stable_branch_name %
        VersionString.components(Project.version)

      Shell.info("Creating stable branch #{name}.")

      git.branch(name).create
    end
  end

  def git
    Git.open('.')
  end
end

#gitObject



18
19
20
# File 'lib/semmy/tasks/branches.rb', line 18

def git
  Git.open('.')
end