Skip to content

Unify the label vocabulary and sync mechanism with Maven - #69

Merged
slachiewicz merged 1 commit into
masterfrom
unify-labels-with-maven
Aug 9, 2026
Merged

slachiewicz merged 1 commit into
masterfrom
unify-labels-with-maven

Conversation

@slachiewicz

Copy link
Copy Markdown
Member

Follows the label audit in #58. This brings codehaus-plexus onto the same label vocabulary and the same sync mechanism as apache/maven-*.

Most plexus components are consumed by Maven and contributors move between the two orgs, so a contributor should not have to learn two vocabularies — and plexus should not maintain a bespoke mechanism when a working one exists next door.

Vocabulary

Adopts the names, descriptions and mostly the colours from apache/maven-gh-actions-shared/.github/labels.js. 26 labels, up from 17.

Taken from Maven:

  • the priority: family — blocker / critical / major / minor / trivial. plexus had no severity vocabulary at all.
  • waiting-for-feedback — Maven's stale workflow keys on this; adopting the name keeps that door open.
  • duplicate, invalid, wontfix — I had dropped these as superseded by GitHub's native close reasons. They all still exist in the repos, so declaring them costs nothing and unification is worth more than the principle.
  • the established colours for enhancement, deprecated, removed and maintenance.

no-changelog becomes skip-changelog, the Maven name, which the shared Maven release-drafter already excludes. Rename rather than recreate, so the nine issues carrying it keep it:

gh label edit no-changelog --name skip-changelog -R codehaus-plexus/<repo>

Four colours deliberately differ from Maven

Maven's set has three collisions:

#912E29  →  maintenance, build
#E4E669  →  invalid, breaking, skip-changelog
#FFFFFF  →  waiting-for-feedback, wontfix

Copying it verbatim would import those into a set that currently has none. So breaking, build and wontfix keep distinct values here, and skip-changelog moves out of the grey range, which is already full at three (duplicate, wontfix, reverted). The same three corrections are worth proposing upstream — they'd touch only build, skip-changelog and wontfix in Maven.

Four labels have no Maven equivalent and are kept: github_actions and question, which exist unmanaged in 83 and 79 Maven repos and deserve declaring in both; need-rebase; and reverted, which Maven's release-drafter already excludes even though no Maven repo defines it.

Mechanism

Replaces sync-labels.sh with a matrix workflow modelled on Maven's labels-sync.yml. Two differences:

  • Repository list from the GitHub API, not gitbox — the ASF has gitbox, codehaus-plexus does not. Archived repos are filtered out, so retired components are never touched. It currently resolves to exactly the 19 repos the shell script hardcoded, and stays correct on its own from here.
  • The scheduled run stays report-only and needs no credentials. Reading labels from a public repo requires no permissions, so drift is detected on the default GITHUB_TOKEN; it reports per label what drifted and fails if anything did. Only apply: true needs LABEL_SYNC_TOKEN.

Maven's sync has neither a read-only mode nor a schedule — that part is worth offering back upstream once it has run here for a while.

Verification

  • labels.js parses; 26 labels, no two sharing a colour (checked by script; closest pair is documentation/dependencies at RGB distance 19, both entrenched GitHub/Dependabot defaults that rarely share a screen).
  • The repo-list command was run for real and returns one valid JSON array of 19 repos. The obvious form of it does not — --paginate with --jq emits one array per page, which would break the matrix; hence the jq -Rsc slurp.
  • The drift logic was dry-run against plexus-utils, plexus-xml and this repo, and correctly reports which labels differ and whether by colour, description or both.
  • Every label referenced by release-drafter.yml exists in labels.js.

Expect the first scheduled run after merge to report drift on every repo — that is correct, and clears once someone reconciles.

Most plexus components are consumed by Maven and contributors move
between the two orgs, so a contributor should not have to learn two
vocabularies, and plexus should not maintain a bespoke mechanism when a
working one already exists next door.

Vocabulary
----------
Adopts the names, descriptions and - with four exceptions - the colours
from apache/maven-gh-actions-shared/.github/labels.js. Taken from Maven:
the priority: family, which plexus had no equivalent of at all;
waiting-for-feedback; duplicate, invalid and wontfix, which all still
exist in the repos and so cost nothing to declare; and the established
colours for enhancement, deprecated, removed and maintenance.

no-changelog becomes skip-changelog, the Maven name, which the shared
Maven release-drafter config already excludes. release-drafter.yml is
updated to match. Rename the label rather than recreating it, so the
nine issues carrying it keep it:

    gh label edit no-changelog --name skip-changelog -R codehaus-plexus/<repo>

Four colours deliberately differ from Maven, because Maven's set has
three collisions - #912E29 on both maintenance and build, #E4E669 on
invalid, breaking and skip-changelog, and #FFFFFF on both wontfix and
waiting-for-feedback. Copying it verbatim would import those into a set
that currently has none, so breaking, build and wontfix keep distinct
values and skip-changelog moves out of the crowded grey range. The same
corrections are worth proposing upstream.

Four labels have no Maven equivalent and are kept: github_actions and
question, which exist unmanaged in 83 and 79 Maven repos and deserve
declaring in both; need-rebase; and reverted, which the Maven
release-drafter already excludes even though no Maven repo defines it.

Mechanism
---------
Replaces sync-labels.sh with a matrix workflow modelled on Maven's
labels-sync.yml, so the two orgs are recognisably the same. Two
differences. The repository list comes from the GitHub API rather than
gitbox, which the ASF has and codehaus-plexus does not; archived repos
are filtered out, so retired components are never touched. And the
scheduled run stays report-only on the default token - reading labels
from a public repo needs no permissions - reporting per-label what
drifted and failing if anything did. Maven's sync has neither a
read-only mode nor a schedule, which is worth offering back.

Generated-by: Claude Opus 5 (1M context)
@slachiewicz slachiewicz added the maintenance Cleanup, refactoring or other internal change label Aug 9, 2026
@slachiewicz
slachiewicz marked this pull request as ready for review August 9, 2026 11:10
@slachiewicz
slachiewicz merged commit 5532336 into master Aug 9, 2026
@slachiewicz
slachiewicz deleted the unify-labels-with-maven branch August 9, 2026 11:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

maintenance Cleanup, refactoring or other internal change

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant