Skip to content

Add label syncing workflow#47

Merged
cgwalters merged 1 commit intobootc-dev:mainfrom
cgwalters:label-syncer
Nov 21, 2025
Merged

Add label syncing workflow#47
cgwalters merged 1 commit intobootc-dev:mainfrom
cgwalters:label-syncer

Conversation

@cgwalters
Copy link
Copy Markdown
Contributor

Add labels.toml to define standard labels that should exist across all repositories in the organization. Add sync-labels workflow that ensures these labels are created in all active repositories when labels.toml is updated.

The workflow uses the app token to access all org repositories and creates any missing labels. Uses TOML format with Python's tomllib for clean parsing with native comment support. Python writes directly to GITHUB_OUTPUT instead of piping through bash. Uses fromJSON() for secure interpolation of the labels array in the github-script action. Runs on pushes to main or can be triggered manually with test mode.

Assisted-by: Claude Code (Sonnet 4.5)

@gemini-code-assist
Copy link
Copy Markdown

Summary of Changes

Hello @cgwalters, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request aims to standardize and automate the management of GitHub labels across the organization's repositories. By introducing a central labels.toml file and an accompanying GitHub Actions workflow, it ensures consistency in labeling, making it easier to categorize issues and pull requests while reducing manual overhead.

Highlights

  • Standardized Labels: Introduces a labels.toml file to define a set of standard labels that should be present across all repositories within the organization, starting with 'needs-rebase' and 'triaged'.
  • Automated Label Syncing: Implements a sync-labels GitHub Actions workflow that automatically creates any missing labels in active repositories whenever labels.toml is updated.
  • Implementation Details: The workflow uses Python with tomllib for parsing the TOML file, writes directly to GITHUB_OUTPUT, and uses fromJSON() for secure interpolation of the labels array. It runs on pushes to main or can be manually triggered in test mode.
Ignored Files
  • Ignored by pattern: .github/workflows/** (1)
    • .github/workflows/sync-labels.yml
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request adds a labels.toml file to define a standard set of labels for repositories. The TOML file format is a good choice for this configuration. My review includes a suggestion to make the label definitions more robust by including color and description, which will improve consistency across repositories. Additionally, please note that while the title and description mention a sync-labels workflow, this file is missing from the pull request. It should be included for this feature to be complete.

Comment thread labels.toml
Add labels.toml to define standard labels that should exist across all
repositories in the organization. Add sync-labels workflow that ensures
these labels are created in all active repositories when labels.toml is
updated.

The workflow uses the app token to access all org repositories and
creates any missing labels or updates existing labels if their color or
description has changed. Uses TOML format with Python's tomllib for
clean parsing. Python writes directly to GITHUB_OUTPUT. Uses fromJSON()
for secure interpolation of the labels array in the github-script action.
Runs on pushes to main or can be triggered manually with test mode.

Labels are defined with name, color, and description properties for
better control and documentation across all repositories.

Assisted-by: Claude Code (Sonnet 4.5)
Signed-off-by: Colin Walters <walters@verbum.org>
@cgwalters cgwalters enabled auto-merge (squash) November 21, 2025 17:28
@cgwalters cgwalters requested a review from ckyrouac November 21, 2025 17:29
@cgwalters cgwalters merged commit c74f639 into bootc-dev:main Nov 21, 2025
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants