Exception: Berkshelf::GitError

Inherits:
BerkshelfError show all
Defined in:
lib/berkshelf/errors.rb

Direct Known Subclasses

PrivateGitRepo

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from BerkshelfError

status_code

Constructor Details

#initialize(stderr) ⇒ GitError

Returns a new instance of GitError.



60
61
62
# File 'lib/berkshelf/errors.rb', line 60

def initialize(stderr)
  @stderr = stderr
end

Instance Attribute Details

#stderrObject (readonly)

Returns the value of attribute stderr.



58
59
60
# File 'lib/berkshelf/errors.rb', line 58

def stderr
  @stderr
end

Instance Method Details

#to_sObject



64
65
66
67
# File 'lib/berkshelf/errors.rb', line 64

def to_s
  out = "An error occured during Git execution:\n"
  out << stderr.prepend_each("\n", "\t")
end