Agent skill

Git PR Workflow

by andymai in andymai/brepjs

This skill should be used when committing, pushing, branching, or merging in the brepjs repository — when a task involves "pre-commit hook failed" (which tier ran, how to bypass), "commit rejected…

Apache-2.0Auto-check passedDevelopment

Install Git PR Workflow

skills CLI
$ npx skills add andymai/brepjs --skill git-pr-workflow -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install andymai/brepjs git-pr-workflow --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/andymai/brepjs.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.claude/skills/git-pr-workflow .claude/skills/git-pr-workflow && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
git-pr-workflow
GitHub stars
114
Token cost
~2.9k tokens
SKILL.md length
1,233 words
Files
1
Skills in repo
21
Repo updated
First seen
Licence
Apache-2.0

At a glance

This skill should be used when committing, pushing, branching, or merging in the brepjs repository — when a task involves "pre-commit hook failed" (which tier ran, how to bypass), "commit rejected…

  • Works in 6 steps: Push the branch and open a PR filling… → CI runs the jobs feeding ci-pass:… → The benchmark job posts a PR comment… → …
  • Tasks that involve Git worktrees
  • SKILL.md covers Quick map, Pre-commit anatomy, commit-msg and pre-push and Commits, plus 4 more sections
  • Calls npm, git and gh

What it does

Git PR Workflow is an agent skill from andymai/brepjs. This skill should be used when committing, pushing, branching, or merging in the brepjs repository — when a task involves "pre-commit hook failed" (which tier ran, how to bypass), "commit rejected by commitlint", "subject may not be empty", the pre-push knip tier firing, "create a branch", "set up a worktree", "open a PR", "arm auto-merge", or deciding whether a commit needs a ! breaking marker. Covers hook anatomy and tiers, conventional-commit message format, branching, worktrees, and the PR/merge process. For…

Its SKILL.md is about 2.9k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Development, covering Git worktrees, Linting and formatting and Commit messages. It works with Git, npm and Prettier. The repository describes itself as: Web CAD library with exact B-Rep geometry. The licence is Apache-2.0.

When your agent uses it

  • Tasks that involve Git worktrees
  • Tasks that involve Linting and formatting
  • Tasks that involve Commit messages

Example prompts

  • “pre-commit hook failed”
  • “commit rejected by commitlint”
  • “subject may not be empty”
  • “/git-pr-workflow”

Requirements

  • Node.js

Workflow steps

6 steps, taken from the first numbered list in SKILL.md.

  1. Push the branch and open a PR filling .github/pull_request_template.md (what/how-to-test/checklist).
  2. CI runs the jobs feeding ci-pass: typecheck, lint (eslint + format:check), quality (check:boundaries + check:patterns + knip), build…
  3. The benchmark job posts a PR comment comparing against main with a 25% regression threshold.
  4. Reviews: branch protection on main requires only the ci-pass status check — zero required approvals. Two AI reviewers (Greptile…
  5. Merge is squash-only; the squash commit title becomes the release-please changelog entry, so make the PR title a valid conventional commit.
  6. After merge: checkout main and pull immediately (the remote branch is auto-deleted).

What it can do on your machine

Read from SKILL.md and the folder at commit e8fa511. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • npm
    • git
    • gh
    • npx
    • eslint
    • prettier
    • vitest
    • bash

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use npm, git, gh and npx, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Git PR Workflow loads about 2.9k tokens when it runs. Until then it costs about 157 tokens; SKILL.md has 1,233 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~157
When it runs · the whole SKILL.md, loaded when a task matches
~2.9k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from andymai/brepjs at commit e8fa511, republished under its Apache-2.0 licence (© andymai). 1,233 words, ~2,946 tokens.

Download SKILL.mdSave it as .claude/skills/git-pr-workflow/SKILL.md (or your agent's skills folder).
name
git-pr-workflow
description
This skill should be used when committing, pushing, branching, or merging in the brepjs repository — when a task involves "pre-commit hook failed" (which tier ran, how to bypass), "commit rejected by commitlint", "subject may not be empty", the pre-push knip tier firing, "create a branch", "set up a worktree", "open a PR", "arm auto-merge", or deciding whether a commit needs a `!` breaking marker. Covers hook anatomy and tiers, conventional-commit message format, branching, worktrees, and the PR/merge process. For diagnosing a specific gate or lint error see quality-gates; for a red CI job see ci-triage.

Git hooks, commits, and PR flow

Hooks are managed by husky (core.hooksPath → .husky/_, installed by the prepare script in package.json). The repo CLAUDE.md "Git hooks" section summarizes the tiers; this skill covers what to do when a gate fires and the traps around commits, worktrees, and merging.

Quick map

ConcernWhere it lives
Hook scripts.husky/pre-commit, .husky/pre-push, .husky/commit-msg
lint-staged config.lintstagedrc.json (NOT in package.json)
Commit message rulescommitlint.config.js (@commitlint/config-conventional)
Local full gatenpm run validate (scripts/validate-change.sh)
CI gate for mergeci-pass job in .github/workflows/ci.yml — the only required status check
PR template.github/pull_request_template.md
Merge methodSquash only; branch auto-deleted on merge

Pre-commit anatomy

.husky/pre-commit runs three tiers; a trap prints scripts/pre-commit-help.sh on any failure.

Tier 1 (parallel):

  • npx lint-staged — per .lintstagedrc.json: src/**/*.ts gets eslint --fix + prettier --write + the pattern checker (scripts/check-patterns.ts); tests/**/*.ts gets eslint + prettier only; *.config.ts and *.md get prettier only. The pattern checker runs only on src/ files.
  • npm run typecheck
  • npm run check:boundaries:staged — the staged variant (scripts/check-layer-boundaries.sh --staged), not plain check:boundaries. On failure, see the architecture-navigation skill.

Tier 2: npm run test — changed-file tests on the occt-wasm kernel, no coverage thresholds (vitest run --project occt-wasm --changed). Set FULL_TESTS=1 to run npm run test:full (full suite with coverage) instead. Test failures: see the writing-tests skill.

Tier 3 (non-blocking, always exit 0):

  • npm run check:readme-reminders — lists READMEs adjacent to staged .ts files that may need updating.
  • bash scripts/check-function-lookup.sh — fires when a staged path matches src/**Fns.ts (any depth) or an index.ts at one directory level (src/index.ts or src/<dir>/index.ts) without docs/function-lookup.md. Act on this one: run npm run docs:generate-lookup and stage the result. The local reminder is soft and its index.ts match is shallow (a deeper src/kernel/occt/index.ts won't trip it), but CI's build job is the authoritative gate at any depth — it regenerates, prettier-normalizes, and git diff --exit-codes the file.

Before committing multi-file changes, prefer npm run validate (typecheck → lint → boundaries → format:check → changed tests) and read its output — do not commit on a partially green tree.

Bypass with git commit --no-verify only as a last resort; CI runs strictly more than the hook, so a bypassed failure just moves to the PR.

Note: scripts/pre-commit-help.sh and CONTRIBUTING.md still say coverage thresholds are enforced "at push time" / "in pre-commit hooks". That is stale — coverage thresholds run only in the main-branch-only, non-blocking coverage CI job. Locally they run only via npm run test:full.

commit-msg and pre-push

  • .husky/commit-msg runs commitlint --edit with @commitlint/config-conventional. A rejected message means the format is wrong, not the content — fix the type(scope): subject shape.
  • .husky/pre-push runs only npm run knip (unused-code detection, ~2 seconds). The full test suite is intentionally not re-run on push; CI's sharded test job is the full gate. If knip fails, either use the newly-flagged export or remove it — do not add it to knip.config.ts without cause.
  • If a push looked odd (interrupted terminal, unusual delay), verify it landed: git ls-remote origin <branch>.

Commits

Format: type(scope): subject. Types and examples: CONTRIBUTING.md "Commit Conventions" (feat, fix, docs, style, refactor, perf, test, chore).

The ! breaking-marker trap. In release-please-config.json, the root brepjs package excludes apps and every packages/* workspace, so satellite-only commits never touch the root version. Everything else at the repo root — including docs/, scripts/, and CI config — feeds the root release. Any commit with ! (or a BREAKING CHANGE: footer) touching those paths major-bumps the published brepjs library. Never put ! on site, docs, or tooling commits. When a change genuinely is breaking, confirm it touches the library surface (src/) before marking it. Full release pipeline: release-publishing skill.

Branches and worktrees

  • Branch naming: <type>/<kebab-description> where type is the conventional-commit type of the work — feat/judge-graded-reference-verdict, fix/memory-leak, docs/api-examples. (CONTRIBUTING.md shows an older feature/ prefix; current practice uses the commit type.)

  • Worktrees for parallel branches go under .worktrees/<branch> inside the repo — gitignored (.gitignore) and excluded from the root vitest suite (vitest.config.ts excludes .worktrees/** and .claude/worktrees/**, because a stale worktree copy without WASM set up would otherwise fail the root suite):

    bash
    git worktree add .worktrees/feat-my-change feat/my-change
  • Run gh pr merge from the main repo path, never from inside the worktree — deleting the branch while its worktree has it checked out fails.

  • After merge: git worktree remove .worktrees/<branch>, then in the main tree git checkout main && git pull. The repo deletes branches on merge, so the local branch goes [gone]; prune with git fetch --prune.

Show full SKILL.md (528 more words)Show less

PR flow

  1. Push the branch and open a PR filling .github/pull_request_template.md (what/how-to-test/checklist).
  2. CI runs the jobs feeding ci-pass: typecheck, lint (eslint + format:check), quality (check:boundaries + check:patterns + knip), build (including the docs/function-lookup.md staleness diff), playground-build, per-package jobs (viewer/verify/sheetmetal/bim), voxel-wasm-rust, the 4-way-sharded test job, size, and benchmark. The coverage job runs on main only, continue-on-error, and is not part of ci-pass. CI failures: see the ci-triage skill.
  3. The benchmark job posts a PR comment comparing against main with a 25% regression threshold.
  4. Reviews: branch protection on main requires only the ci-pass status check — zero required approvals. Two AI reviewers (Greptile, configured in .greptile/config.json, and cubic) review every PR but are not required checks. Wait for both AI reviews to land before arming gh pr merge --auto — auto-merge armed early merges the moment ci-pass goes green, and real defects have been caught in reviews that arrived post-merge.
  5. Merge is squash-only; the squash commit title becomes the release-please changelog entry, so make the PR title a valid conventional commit.
  6. After merge: checkout main and pull immediately (the remote branch is auto-deleted).

Release PRs (release-please--* head refs) skip the code-CI path and are auto-merged by .github/workflows/release-please.yml with strict ordering: the root brepjs release PR merges first; leaf release PRs (cad/bim/sheetmetal) are held while root is open, because the node-workspace plugin pins leaves to the pending root version — merging a leaf early leaves main pinned to an unpublished version and breaks npm ci with ETARGET. brepjs-opencascade is permanently held for manual merge. Do not manually merge release PRs out of this order.

Symptom → cause → fix

SymptomCauseFix
Pre-commit fails with layer VIOLATIONUpward import across layersarchitecture-navigation skill; npm run check:boundaries for the full report
Pre-commit fails in check-patternsNew pattern violation in staged src/ fileSee quality-gates (fix vs. baseline)
Every open PR fails quality/check:patternsUnbaselined violation reached main (CI checks the PR merged with main)See quality-gates (baseline-bump-first recovery)
CI build fails on git diff --exit-code docs/function-lookup.mdStale generated lookup after *Fns.ts changeSee adding-operations (function-lookup gate)
Commit rejected: "subject may not be empty" / "type must be one of"Message not type(scope): subjectRewrite per CONTRIBUTING.md commit types
Published brepjs unexpectedly major-bumped! or BREAKING CHANGE: on a docs/tooling commitNever mark non-library commits breaking; docs/ is not in root exclude-paths
P1 review comment appears after mergeAuto-merge armed before AI reviews landedWait for Greptile + cubic before gh pr merge --auto
npm ci fails ETARGET after a release mergeLeaf release PR merged while root brepjs release was openMerge root first; let the workflow regenerate leaf PRs
git worktree remove or branch delete failsBranch checked out in a worktree / merge run from inside itOperate from the main repo path; remove the worktree first
Local branch shows [gone] after mergedelete_branch_on_merge removed the remote branchgit checkout main && git pull && git fetch --prune, delete the local branch

Additional resources

  • CLAUDE.md — "Git hooks" and "Commits" sections (concise summary of the above)
  • CONTRIBUTING.md — Development Workflow, Commit Conventions, Pull Request Process
  • .claude/commands/verify.md — wraps npm run validate + the function-lookup reminder
  • Sibling skills: architecture-navigation (boundary failures), writing-tests (test failures), quality-gates (lint/pattern/knip details), ci-triage (CI job debugging), release-publishing (release-please pipeline)

© andymai, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .claude/skills/git-pr-workflow of andymai/brepjs.

Open the folder on GitHubat commit e8fa511

Compare with similar skills

Git PR Workflow next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Git PR Workflow compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Git PR Workflow this skillandymai/brepjs114—~2.9kAutomated safety check: PassApache-2.0
Verdaccio Pull Request Workflowverdaccio/verdaccio18k—~1.9kAutomated safety check: PassMIT
Lint Commit PRTresjs/tres3.8k—~1.1kAutomated safety check: PassMIT
PR Pushicebear0828/codex-proxy1.8k—~2.2kAutomated safety check: NotesCustom licence
PR Pushicebear0828/codex-proxy1.8k—~2.3kAutomated safety check: NotesCustom licence
Squad Git Branching Workflowmicrosoft/waza1.4k4 repos~1.5kAutomated safety check: PassMIT

Similar skills

  • Takes a change through a verdaccio pull request: branch, local checks, changeset, title and body, labels, CI and review rounds, and ports to other release lines.

    18k GitHub stars~1.9k tokensUpdated today
    DevelopmentAuto-check passed
  • Lint Commit PR

    Tresjs/tres

    Lint local changes, auto-fix, conventional commit, and optionally create PR

    3.8k GitHub stars~1.1k tokensUpdated today
    DevelopmentAuto-check passed
  • PR Push

    icebear0828/codex-proxy

    Package the current working changes into a standards-compliant codex-proxy pull request: branch hygiene, commit message linting, CHANGELOG prompt, conventional commit, push, and gh pr create against…

    1.8k GitHub stars~2.2k tokensUpdated yesterday
    DevelopmentAuto-check: notes
  • PR Push

    icebear0828/codex-proxy

    Package the current working changes into a standards-compliant codex-proxy pull request: branch hygiene, commit message linting, CHANGELOG prompt, conventional commit, push, and gh pr create against…

    1.8k GitHub stars~2.3k tokensUpdated yesterday
    DevelopmentAuto-check: notes
  • Official

    Dev-first branching model for the Squad project: feature work branches from dev, issue branches follow a naming rule and parallel issues use git worktrees.

    1.4k GitHub starsUsed in 4 repos~1.5k tokens
    DevelopmentAuto-check passed
  • Obsidian Plugin Release

    crafter-station/skills

    Release a new version of an Obsidian community plugin without forgetting steps.

    111 GitHub stars~1.8k tokensUpdated 29 days ago
    DevelopmentAuto-check passed

More from andymai/brepjs

All 21 skills in this repo
  • Implement

    andymai/brepjs

    A skill your agent uses when authoring or editing a brepjs .brep.ts part — writing the geometry with the functional API (box, cylinder, fuse, cut, fillet, sketch→extrude…), declaring an expected…

    114 GitHub stars~3.4k tokensUpdated today
    Auto-check passed
  • Memory And Disposal

    andymai/brepjs

    This skill should be used when managing WASM handle lifetimes or hunting memory leaks in brepjs — when a task mentions "createHandle() without using keyword risks WASM memory leak"…

    114 GitHub stars~3.1k tokensUpdated today
    Auto-check passed
  • Polish

    andymai/brepjs

    A skill your agent uses when a valid brepjs part should look designed rather than glued-from-primitives (products, toys, mechanisms, anything a human eyeballs), and when exporting/handing off the…

    114 GitHub stars~588 tokensUpdated today
    Auto-check passed
  • Wasm Interop

    andymai/brepjs

    This skill should be used when working across the JS/WASM boundary in brepjs — writing or debugging code in src/kernel/occt, src/kernel/occtWasm, or src/kernel/brepkit, or diagnosing symptoms like…

    114 GitHub stars~3k tokensUpdated today
    Auto-check passed
  • Writing Tests

    andymai/brepjs

    This skill should be used when writing, running, or fixing tests in the brepjs repository — when a task says "add a test", "write a regression test", "tests are failing", "test timed out", "coverage…

    114 GitHub stars~4.3k tokensUpdated today
    Auto-check passed
  • Adding Operations

    andymai/brepjs

    This skill should be used when adding or extending a geometric shape operation in brepjs — the end-to-end recipe once the target module is chosen (which is decided by architecture-navigation) — when…

    114 GitHub stars~4.4k tokensUpdated today
    Auto-check passed

Works with

Categories

Questions about Git PR Workflow

What does Git PR Workflow do?

This skill should be used when committing, pushing, branching, or merging in the brepjs repository — when a task involves "pre-commit hook failed" (which tier ran, how to bypass), "commit rejected…. Git PR Workflow is an agent skill from andymai/brepjs. This skill should be used when committing, pushing, branching, or merging in the brepjs repository — when a task involves "pre-commit hook failed" (which tier ran, how to bypass), "commit rejected by commitlint", "subject may not be empty", the pre-push knip tier firing, "create a branch", "set up a worktree", "open a PR", "arm auto-merge", or deciding whether a commit needs a !

When should I use Git PR Workflow?

Git PR Workflow fits situations like: tasks that involve Git worktrees; tasks that involve Linting and formatting; tasks that involve Commit messages.

How do I install Git PR Workflow in Claude Code?

Run `npx skills add andymai/brepjs --skill git-pr-workflow -a claude-code`. Or copy the skill folder (.claude/skills/git-pr-workflow in andymai/brepjs) into .claude/skills/git-pr-workflow in your project. Claude Code loads it when a task matches its description.

How do I install Git PR Workflow in Codex?

Run `npx skills add andymai/brepjs --skill git-pr-workflow -a codex`. Or copy the skill folder (.claude/skills/git-pr-workflow in andymai/brepjs) into .agents/skills/git-pr-workflow in your project. Codex loads it when a task matches its description.

Can I use Git PR Workflow in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add andymai/brepjs --skill git-pr-workflow -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/git-pr-workflow, .gemini/skills/git-pr-workflow, .github/skills/git-pr-workflow and .opencode/skills/git-pr-workflow in your project.

What does Git PR Workflow need to run?

Going by SKILL.md and its folder, Git PR Workflow needs the command-line tools its instructions call (npm, git, gh, npx, eslint and prettier). Our summary lists: Node.js.

Does Git PR Workflow access the network?

SKILL.md contains no URLs. Its commands use npm, git, gh and npx, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is Git PR Workflow safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Git PR Workflow use?

Git PR Workflow is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Git PR Workflow use?

About 2.9k tokens (SKILL.md is roughly 12k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Git PR Workflow?

Skills that share tags, products or a category with Git PR Workflow: Verdaccio Pull Request Workflow (verdaccio/verdaccio, 18k stars), Lint Commit PR (Tresjs/tres, 3.8k stars), PR Push (icebear0828/codex-proxy, 1.8k stars) and PR Push (icebear0828/codex-proxy, 1.8k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Git PR Workflow?

andymai (a GitHub user) maintains it in andymai/brepjs, which has 114 GitHub stars. The repository holds 21 skills in this directory. The repository was last updated on October 6, 2026.

Source: andymai/brepjs on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.