class Gollum::Git::Actor

Attributes

email[RW]
name[RW]
time[RW]

Public Class Methods

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

Public Instance Methods

output(time) click to toggle source
# File lib/rugged_adapter/git_layer_rugged.rb, line 46
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 57
def to_h
  {:name => @name, :email => @email, :time => @time}
end