class Gollum::Git::Actor

Attributes

email[RW]
name[RW]

Public Class Methods

default_actor() click to toggle source
# File lib/rugged_adapter/git_layer_rugged.rb, line 23
def self.default_actor
  self.new("Gollum", "Gollum@wiki")
end
new(name, email) click to toggle source
# File lib/rugged_adapter/git_layer_rugged.rb, line 27
def initialize(name, email)
  @name = name
  @email = email
end

Public Instance Methods

output(time) click to toggle source
# File lib/rugged_adapter/git_layer_rugged.rb, line 32
def output(time)
  # implementation from grit
  offset = time.utc_offset / 60
  "%s <%s> %d %+.2d%.2d" % [
  @name,
  @email || "null",
  time.to_i,
  offset / 60,
  offset.abs % 60]
end
to_h() click to toggle source
# File lib/rugged_adapter/git_layer_rugged.rb, line 43
def to_h
  {:name => @name, :email => @email}
end