GitCommit class Getting started

A commit object: its tree, parents, identities and message.

The dates are the instants git recorded, expressed in UTC. A git commit also records the time zone its author and committer were in; a DateTime cannot carry an arbitrary offset, so that offset is not kept here.

Constructors

GitCommit({required GitOid tree, required List<GitOid> parents, required GitIdentity author, required DateTime authorDate, required GitIdentity committer, required DateTime committerDate, required String message})
Creates a commit of tree, parents, author, committer and message.

Properties

author → GitIdentity
Identity that authored the commit.
final
authorDate → DateTime
Instant the commit was authored, in UTC.
final
committer → GitIdentity
Identity that committed the commit.
final
committerDate → DateTime
Instant the commit was created, in UTC.
final
hashCode → int
The hash code for this object.
no setteroverride
message → String
Commit message, subject and body, without git's trailing newline.
final
parents → List<GitOid>
Parent commits in order; empty for a root commit and two entries for an ordinary merge commit.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
tree → GitOid
Tree object the commit snapshots.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
override

Operators

operator ==(Object other) → bool
The equality operator.
override