Class: Git::GitCommit
- Inherits:
-
Object
- Object
- Git::GitCommit
- Defined in:
- lib/git/git_commit.rb
Instance Attribute Summary collapse
-
#author_email ⇒ Object
readonly
Returns the value of attribute author_email.
-
#author_name ⇒ Object
readonly
Returns the value of attribute author_name.
-
#commit_date ⇒ Object
readonly
Returns the value of attribute commit_date.
-
#message ⇒ Object
readonly
Returns the value of attribute message.
-
#repository_name ⇒ Object
readonly
Returns the value of attribute repository_name.
-
#sha ⇒ Object
readonly
Returns the value of attribute sha.
Instance Method Summary collapse
- #==(other) ⇒ Object
-
#initialize(sha, message, commit_date, author_name, author_email, repository_name:) ⇒ GitCommit
constructor
A new instance of GitCommit.
- #to_s ⇒ Object
Constructor Details
#initialize(sha, message, commit_date, author_name, author_email, repository_name:) ⇒ GitCommit
Returns a new instance of GitCommit.
7 8 9 10 11 12 13 14 |
# File 'lib/git/git_commit.rb', line 7 def initialize(sha, , commit_date, , , repository_name:) @sha = sha @message = @commit_date = commit_date @author_email = @author_name = @repository_name = repository_name end |
Instance Attribute Details
#author_email ⇒ Object (readonly)
Returns the value of attribute author_email.
5 6 7 |
# File 'lib/git/git_commit.rb', line 5 def @author_email end |
#author_name ⇒ Object (readonly)
Returns the value of attribute author_name.
5 6 7 |
# File 'lib/git/git_commit.rb', line 5 def @author_name end |
#commit_date ⇒ Object (readonly)
Returns the value of attribute commit_date.
5 6 7 |
# File 'lib/git/git_commit.rb', line 5 def commit_date @commit_date end |
#message ⇒ Object (readonly)
Returns the value of attribute message.
5 6 7 |
# File 'lib/git/git_commit.rb', line 5 def @message end |
#repository_name ⇒ Object (readonly)
Returns the value of attribute repository_name.
5 6 7 |
# File 'lib/git/git_commit.rb', line 5 def repository_name @repository_name end |
#sha ⇒ Object (readonly)
Returns the value of attribute sha.
5 6 7 |
# File 'lib/git/git_commit.rb', line 5 def sha @sha end |
Instance Method Details
#==(other) ⇒ Object
20 21 22 |
# File 'lib/git/git_commit.rb', line 20 def ==(other) sha == other.sha end |
#to_s ⇒ Object
16 17 18 |
# File 'lib/git/git_commit.rb', line 16 def to_s sha end |