Skip to content

Commit

🛈 DocStrings

Source code in src/githarbor/core/models.py
@dataclass
class Commit:
    sha: str
    """Unique identifier for the commit."""
    message: str
    """Commit message."""
    author: User | None = None
    """User who authored the commit."""
    created_at: datetime | None = None
    """Date and time when the commit was authored."""
    committer: User | None = None
    """User who committed the changes."""
    url: str | None = None
    """URL to the commit details."""
    stats: dict[str, int] = field(default_factory=dict)
    """Commit statistics."""
    parents: list[str] = field(default_factory=list)
    """List of parent commit SHAs."""
    verified: bool = False
    """Signature verification status."""
    files_changed: list[str] = field(default_factory=list)
    """Changed file paths."""

author class-attribute instance-attribute

author: User | None = None

User who authored the commit.

committer class-attribute instance-attribute

committer: User | None = None

User who committed the changes.

created_at class-attribute instance-attribute

created_at: datetime | None = None

Date and time when the commit was authored.

files_changed class-attribute instance-attribute

files_changed: list[str] = field(default_factory=list)

Changed file paths.

message instance-attribute

message: str

Commit message.

parents class-attribute instance-attribute

parents: list[str] = field(default_factory=list)

List of parent commit SHAs.

sha instance-attribute

sha: str

Unique identifier for the commit.

stats class-attribute instance-attribute

stats: dict[str, int] = field(default_factory=dict)

Commit statistics.

url class-attribute instance-attribute

url: str | None = None

URL to the commit details.

verified class-attribute instance-attribute

verified: bool = False

Signature verification status.

:fa-brands-github: Show source on GitHub