class GitReflow::Workflows::Core
This class contains the core workflow for git-reflow. Going forward, this will act as the base class for customizing and extending git-reflow.
Public Class Methods
load_raw_workflow(workflow_string)
click to toggle source
Evaluates the provided string in the context of this class
@param workflow_string [String] the contents of a Workflow
file to eval
# File lib/git_reflow/workflows/core.rb, line 23 def self.load_raw_workflow(workflow_string) return if workflow_string.strip.empty? ::GitReflow.logger.debug "Evaluating workflow..." binding.eval(workflow_string) end
load_workflow(workflow_path)
click to toggle source
Reads and evaluates the provided file in the context of this class
@param workflow_path [String] the path of the Workflow
file to eval
# File lib/git_reflow/workflows/core.rb, line 14 def self.load_workflow(workflow_path) return unless workflow_path.length > 0 and File.exists?(workflow_path) ::GitReflow.logger.debug "Using workflow: #{workflow_path}" self.load_raw_workflow(File.read(workflow_path)) end