agentleFS
AI-AnswerAI-Answer/Agent-Club/.claude/skills/oss-pr/SKILL.md

oss-pr

Skill9 starsChanged 8 months agoApache-2.0View on GitHub

Use when creating a pull request, after committing changes, or when user invokes /oss-pr. Covers branch management, quality checks, commit, push, and PR creation.

  • Commits and pushes

2 other projects use a version of this, 2 of them edited.

Adopted by

Most recently taken up by

  • Other versions2 projects use a version of this.

    Word for word · 0

    None found.

    Edited · 2

    1. FerroxLabs/wayland★ 606100% same
    2. CES-Ltd/TitanX★ 4795% same

    Wrote their own version · 0

    None found.

    How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.

  • In this repository13 other files it gives its agents.

The file

We split this skill into the rules it gives an agent

6 rules. About 0 are common, 4 are distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈4

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  • could be automatic: a setting could enforce it
  1. Distinctive:

    If already on a feature branch: proceed directly

    line 25
  2. Distinctive:

    If on main or master: auto-generate a branch name, create and switch immediately — no confirmation needed

    line 26
  3. Very specific:

    Create branch {username}/{type}/{slug} directly and announce the name chosen.

    line 39
  4. Very specific:

    Run in this order: format → lint → tsc.

    line 58
  5. Distinctive:

    If push fails due to remote rejection, inform user.

    line 109
  6. Distinctive:

    Run git log main..HEAD --oneline and git diff main...HEAD to understand all changes, then:

    line 113

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

OSS PR

Smart commit + PR workflow: branch management → quality checks → tests → commit → push → PR.

Announce at start: "Using oss-pr skill to commit and open a pull request."

Workflow

Step 0: Gather Info

git branch --show-current
git diff --name-only HEAD
git status --short
git config user.name

Branch rules:

  • If already on a feature branch: proceed directly
  • If on main or master: auto-generate a branch name, create and switch immediately — no confirmation needed

Auto-generating a branch name:

Analyze the changed files from git diff --name-only HEAD to infer:

  1. type — pick one: feat / fix / refactor / chore
    • feat: new user-facing functionality
    • fix: bug fix
    • refactor: restructuring without behavior change
    • chore: config, scripts, skills, docs, deps
  2. slug — 2–3 lowercase words derived from the most relevant changed paths, joined by hyphens. Keep it short and specific.

Create branch {username}/{type}/{slug} directly and announce the name chosen.

Branch naming reference:

TypeExample
feat{prefix}/feat/dark-mode
fix{prefix}/fix/crash-on-open
refactor{prefix}/refactor/settings
chore{prefix}/chore/update-deps

Step 1: Quality Checks

CommandScopeSkip when
bun run format.ts/.tsx/.css/.json/.mdNever — always run
bun run lint.ts/.tsx onlyNo .ts/.tsx files changed
bunx tsc --noEmit.ts/.tsx onlyNo .ts/.tsx files changed

Run in this order: format → lint → tsc.

  • format → Auto-fixes silently (must run even for non-code files like .md).
  • lint fails → Stop, report errors. Do not proceed.
  • tsc fails → Stop, report errors. Do not proceed.
  • All pass → Proceed to i18n check below.

i18n check (run if any src/renderer/, locales/, or src/common/config/i18n files are modified):

bun run i18n:types
node scripts/check-i18n.js
  • i18n:types fails → Stop, report errors. Do not proceed.
  • check-i18n exits 1 (errors) → Stop, report errors. Do not proceed.
  • check-i18n exits 0 (warnings only) → Continue silently.
  • No i18n-sensitive files changed → Skip both commands.

Step 2: Run Tests

bunx vitest run
  • Fails → Stop, report failing tests. Do not proceed.
  • Passes → Proceed silently.

Step 3: Commit

git status
git diff

Stage all modified files — including any files auto-fixed by format in Step 1:

git add -u

Generate commit message in English using conventional commits format: <type>(<scope>): <subject>.

NEVER include Co-authored-by or any AI attribution.

Step 4: Push Branch

git push -u origin <branch-name>

If push fails due to remote rejection, inform user. NEVER force-push without explicit approval.

Step 5: Create Pull Request

Run git log main..HEAD --oneline and git diff main...HEAD to understand all changes, then:

gh pr create --title "<pr-title>" --body "$(cat <<'EOF'
## Summary

<1-3 bullet points>

## Test plan

- [ ] <verification steps>
EOF
)"

PR title: under 70 characters, <type>(<scope>): <description> format. Reuse commit message if single commit.

NEVER add AI-generated signatures, Generated with, or Co-Authored-By lines.

Step 6: Post-PR

Output the PR URL when done.

Quick Reference

0. Check branch (create if on main)
1. bun run format (ALWAYS) && bun run lint && bunx tsc --noEmit (skip lint/tsc if no .ts/.tsx)
   (if i18n files changed: bun run i18n:types && node scripts/check-i18n.js)
2. bunx vitest run
3. Commit (conventional commits, no AI attribution)
4. git push -u origin <branch>
5. gh pr create
6. Output PR URL

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.