Class: CobraCommander::GitChanged

Inherits:
Object
  • Object
show all
Includes:
Enumerable
Defined in:
lib/cobra_commander/git_changed.rb

Overview

List of files changed in a git repository in the current branch in relation to the give base branch

Constant Summary collapse

Error =
Class.new(StandardError)
InvalidSelectionError =
Class.new(Error)

Instance Method Summary collapse

Constructor Details

#initialize(path, base_branch) ⇒ GitChanged

Returns a new instance of GitChanged.



17
18
19
20
# File 'lib/cobra_commander/git_changed.rb', line 17

def initialize(path, base_branch)
  @path = path
  @base_branch = base_branch
end

Instance Method Details

#each(&block) ⇒ Object



22
23
24
# File 'lib/cobra_commander/git_changed.rb', line 22

def each(&block)
  changes.each(&block)
end