INNER CODE UNIT · Python

format_commit_line

fluxerapp/flutter_client · .github/scripts/append_release_direct_commits.py:181

def format_commit_line(sha: str, title: str, author: str) -> str:
    repository = os.environ["GITHUB_REPOSITORY"]
    short_sha = sha[:7]
    commit_url = f"https://github.com/{repository}/commit/{sha}"
    conventional_match = CONVENTIONAL_COMMIT_PATTERN.match(title)
    if conventional_match is not None:
        display_title = conventional_match.group("title").strip()
    else:
        display_title = title
    return f"- {display_title} (@{author}) ([{short_sha}]({commit_url}))"


def collect_direct_commits(previous_tag: str | None, commitish: str) -> list[DirectCommit]:
    excluded_authors = read_excluded_authors()
    direct_commits: list[DirectCommit] = []
    for sha, subject in list_commits_since_tag(previous_tag, commitish):
        author = fetch_commit_author_login(sha)
        if author in excluded_authors:

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…