Cross Reference: commit.rb
xref
: /
dovecot
/
src
/
lib-index
/
mail-index-sync-ext.c
Home
History
Annotate
Line#
Navigate
Download
Search
only in
./
class
Commit
<
ActiveRecord
::
Base
attr_accessible
:
commit_oid
, :
repository
attr_accessible
:
author_name
, :
author_email
, :
author_date
attr_accessible
:
committer_name
, :
author_email
, :
commit_date
belongs_to
:
author
,
class_name
:
User.to
_s
belongs_to
:
committer
,
class_name
:
User.to
_s
belongs_to
:
pusher
,
class_name
:
User.to
_s
has_many
:
ontology_versions
has_many
:
ontologies
,
through
: :
ontology_versions
belongs_to
:
repository
def
fill_commit_instance
!
data
=
repository.git.commit
_author
(
commit_oid
)
self.author
_name
=
data
[:
name
]
self.author
_email
=
data
[:
email
]
self.author
_date
=
data
[:
time
]
self.author
=
User.where
(
email
:
author_email
)
.
first
data
=
repository.git.commit
_committer
(
commit_oid
)
self.committer
_name
=
data
[:
name
]
self.committer
_email
=
data
[:
email
]
self.commit
_date
=
data
[:
time
]
self.committer
=
User.where
(
email
:
committer_email
)
.
first
save
!
end
end