A Chrome extension that prioritizes and de-emphasizes changed files directly in GitHub's pull-request file tree.
This is a maintained fork of ygongdev/github-pr-filter, redesigned for GitHub's current Files changed UI.
- Adds a Review profile button beside GitHub's Filter options button.
- Assigns changed files to fixed
P0–P3priority groups with consistent colors. - Leaves unmatched Normal files fully visible and reviewable.
- Dims files classified as No review without hiding them by default.
- Temporarily filters priority groups in GitHub's native file tree without removing diff sections.
- Remembers one active Review profile and an optional auto-prepare setting per repository.
- Opens profile configuration in a right-side drawer with a live file-tree preview.
- Copies a repository-aware prompt that asks an AI coding tool for paste-ready profile rules.
- Collapses No-review diffs with Prepare review, either manually or automatically per repository.
- Optionally marks No-review files Viewed through GitHub's native, personal Viewed state.
- Stores profiles and repository assignments in Chrome sync storage. No GitHub token is requested or stored.
- Run
npm install. - Run
npm run build. - Open
chrome://extensions. - Enable Developer mode.
- Choose Load unpacked and select this repository directory.
- Open a pull request's Files changed page.
After rebuilding an already loaded extension, click Reload on chrome://extensions, then reload the pull-request tab.
A Review profile has five multiline rule fields. Each line is one rule, and higher groups win before lower groups or No review.
| Group | Meaning | Appearance |
|---|---|---|
P0 |
Must review | Red badge |
P1 |
High | Orange badge |
P2 |
Medium | Yellow badge |
P3 |
Low, but still requires review | Blue badge |
| Normal | Requires review; matched by no rule | No badge |
| No review | Does not require human review | Dimmed, no badge |
Folders do not receive badges. When tree visibility controls hide every matching file beneath a folder, that empty folder is hidden as well.
Unprefixed rules are globs:
**/*.md
**/migrations/**
Prefix regular expressions with re:. Put flags between re: and the pattern when needed:
re:^features/.+\.entity\.ts$
re:i:^docs/
There is no auto-detection or separate pattern-type control.
- Click the Review profile icon next to GitHub's Filter options button.
- Select a profile for the current
owner/repository, or select None for GitHub's untouched tree. - Toggle
P0,P1,P2,P3, Normal, or No review to temporarily change tree visibility. - Use Review required to hide only No-review files, or Show all to reset the tree.
- Use Prepare review to collapse No-review diffs.
- Optionally enable Auto-prepare this repository to collapse newly loaded No-review diffs on future PR pages.
Auto-prepare never marks files Viewed. Mark Viewed is always an explicit action. Tree visibility resets to all files when the page reloads or another PR opens.
Choose Manage profiles… from the compact menu. The editor opens on the right so the native file tree remains visible.
- Rule changes preview immediately in the tree.
- Copy AI setup prompt includes the current repository, PR, changed-file paths, and draft rules so an AI coding tool with repository access can suggest each priority group.
- Save profile creates or updates a profile and preserves repository assignments when renamed.
- Cancel restores the saved profile and tree state.
- Closing with unsaved changes asks before discarding them.
- Deleting a profile clears every repository assignment that used it.
Version 4 starts with new Review profiles and intentionally does not migrate legacy filter/action settings.
This is a starting point for GamingSystems/cms; tune it against real pull requests.
P0 — Must review
**/*.md
**/migrations/**
**/auth/**
**/permissions/**
**/e2e/**
**/integration/**
P1 — High
re:(^|/)(entities?|adapters?)(/|\.)
P2 — Medium
re:(^|/)(models?|commands?|queries|events?|use-cases?)(/|\.)
re:\.(request|response)(\.dto)?\.ts$
P3 — Low
**/*.service.ts
**/*.controller.ts
No review
**/*.spec.ts
**/*.test.ts
**/index.ts
**/project.json
**/package.json
**/.eslintrc*
Because priorities win, integration, E2E, authentication, and permission tests remain P0 even though the broad No-review rule matches test filenames.
npm run packageThe extension uses GitHub's native Viewed buttons and the logged-in browser session. It does not request or store a personal access token. GitHub's Viewed state is personal and GitHub may unmark a file when that file changes.
MIT, preserving the upstream license and attribution.