Class: Moku::Pipeline::ReadDefaultBranch

Inherits:
Pipeline
  • Object
show all
Defined in:
lib/moku/pipeline/read_default_branch.rb

Overview

Read and print the default branch

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Pipeline

for, #initialize, register, registry

Constructor Details

This class inherits a constructor from Moku::Pipeline::Pipeline

Class Method Details

.handles?(command) ⇒ Boolean

Returns:

  • (Boolean)

12
13
14
# File 'lib/moku/pipeline/read_default_branch.rb', line 12

def self.handles?(command)
  command.action == :read_default_branch
end

Instance Method Details

#callObject


16
17
18
19
20
# File 'lib/moku/pipeline/read_default_branch.rb', line 16

def call
  # Avoid calling step because the logger will be used for output,
  # and calling step would make it less clean.
  print_default_branch
end