Skip to content

ci: label pull requests from their changed paths - #681

Merged
rootsongjc merged 1 commit into
masterfrom
ci/pr-path-labeler
Jul 30, 2026
Merged

ci: label pull requests from their changed paths#681
rootsongjc merged 1 commit into
masterfrom
ci/pr-path-labeler

Conversation

@mesutoezdil

@mesutoezdil mesutoezdil commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Why

Issue labels were applied in a single manual pass. Pull requests carry no area/* label at all, and nothing keeps either up to date as new work arrives.

Mapping a changed path to an area needs no judgement, so it can run on its own. Priority and difficulty still cannot, and are left alone.

What it does

.github/labeler.yml maps paths to the area/* labels.

Label Paths
area/docs docs/, versioned_docs/, versioned_sidebars/, tutorials/, sidebars*.js, versions.json
area/ui src/
area/blog blog/
area/i18n i18n/
area/edge-functions netlify/, netlify.toml
area/ci-infra .github/, scripts/, package*.json, lint and format config
area/seo static/robots.txt, static/llms.txt, docusaurus.config.js

area/ui is new, created to cover src/ (React components, pages, theme, css), which is the largest source directory here and had no area label. It uses the same colour as the rest of the area/* family. Every other label already existed.

Dry run against merged pull requests

Ran the rules against the actual changed file lists:

PR Files Result
#679 .github/ISSUE_TEMPLATE/* area/ci-infra
#678 src/pages/index.js area/ui
#677 .github/workflows/docs-health.yml area/ci-infra
#673 package.json, package-lock.json area/ci-infra
#655 i18n/…, tutorials/…, sidebars-tutorials.js area/i18n, area/docs

Every merged pull request checked now lands on at least one area.

Notes

pull_request_target is used because a pull_request run from a fork gets a read-only token and cannot add labels. The workflow never checks out or executes pull request code, it only reads the changed file list, so the elevated token is not exposed to contributor code. The action is pinned by commit SHA, matching the convention in docs-health.yml.

sync-labels: false means labels are only added, never removed, so a manually applied label is not stripped on the next push.

npm run format:check passes.

@coderabbitai

coderabbitai Bot commented Jul 29, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@mesutoezdil, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 47 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: cbdd00f1-a3ee-42f8-bf15-208add357e2e

📥 Commits

Reviewing files that changed from the base of the PR and between 65354a0 and 0467b7b.

📒 Files selected for processing (2)
  • .github/labeler.yml
  • .github/workflows/pr-labeler.yml

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@hami-robot hami-robot Bot added the size/M label Jul 29, 2026
@netlify

netlify Bot commented Jul 29, 2026

Copy link
Copy Markdown

Deploy Preview for project-hami ready!

Name Link
🔨 Latest commit 0467b7b
🔍 Latest deploy log https://app.netlify.com/projects/project-hami/deploys/6a6a004d6d491600082e8ec3
😎 Deploy Preview https://deploy-preview-681--project-hami.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

Issue labels were applied by hand in a single pass, and pull requests
carried no area label at all. Path to area mapping does not need
judgement, so it can run on its own.

Uses pull_request_target because a pull_request run from a fork gets a
read-only token and cannot add labels. The workflow never checks out or
runs pull request code, it only reads the changed file list.

Signed-off-by: mesutoezdil <mesudozdil@gmail.com>

@rootsongjc rootsongjc left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

/lgtm

@hami-robot

hami-robot Bot commented Jul 30, 2026

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: mesutoezdil, rootsongjc
Once this PR has been reviewed and has the lgtm label, please assign wawa0210 for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@rootsongjc
rootsongjc merged commit d755fd8 into master Jul 30, 2026
12 of 13 checks passed
@rootsongjc
rootsongjc deleted the ci/pr-path-labeler branch July 30, 2026 11:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants