agentleFS
MicrosoftKnown publishermicrosoft/devsquad-copilot/.github/plugins/devsquad/skills/pull-request/SKILL.md

pull-request

Skill50 starsChanged 16 days agoMITView on GitHub

Implementation finalization with PR. Use when implementation is complete and you need to commit, push, or open a pull request. Includes automated reviews and technical debt tracking. Do not use during implementation (use devsquad.implement), for standalone intermediate commits (use git-commit), or for branch creation (use git-branch).

  • Deletes or force-pushes
  • Commits and pushes

We split this skill into the rules it gives an agent

29 rules. 0 are common, 13 are distinctive, and 16 are very specific to this project.

  • 0

    Common

    Most of the 45 edited versions we read keep these.

  • 13

    Distinctive

    This author's own choices. Worth a look.

  • 16

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Use read/changes to list source control changes.

    line 10
  2. Very specific:

    If there are uncommitted changes, use the git-commit skill to commit.

    line 19
  3. Distinctive:

    Before pushing or creating a PR, verify the current branch is not the integration branch:

    line 23
  4. Distinctive:

    If the user chooses [B]:

    line 44
  5. Distinctive:

    If the user chooses [P], proceed with the push.

    line 51
  6. Very specific:

    If the automated review was already executed by devsquad.implement (step 9 of the orchestration flow), do not re-execute review.

    line 57
  7. Distinctive:

    If the user chooses [R] and the automated review was already executed, present the existing result instead of re-executing.

    line 69
  8. Distinctive:

    FAILED: Do not proceed with PR. Present critical findings and offer to fix or escalate for spec/plan review.

    line 93
  9. Very specific:

    When devsquad.review is not invoked automatically, assess if a security review is needed by evaluating the security triggers defined in …

    line 97
  10. Very specific:

    If a trigger is detected, execute devsquad.security as a sub-agent in code mode.

    line 99
  11. Very specific:

    After the result, present the verdict (PASSED / PASSED_WITH_FINDINGS / FAILED) following the same format above.

    line 101
  12. Distinctive:

    If no trigger is detected, proceed with PR.

    line 103
  13. Distinctive:

    If during implementation you find problematic code outside the scope of the current task, record it as a work item.

    line 115
  14. Very specific:

    If confirmed, create the work item following the work-item-creation skill (Tech Debt section).

    line 138
  15. Distinctive:

    Before creating the PR, determine the target branch:

    line 142
  16. Very specific:

    Use Integration Branch from the config.

    line 148
  17. Very specific:

    Read .memory/board-config.md to determine the repo platform.

    line 154
  18. Distinctive:

    If an open PR already exists, inform and ask if they want to update the existing one.

    line 166
  19. Very specific:

    Before calling github/create_pull_request or ado/repo_pull_request_write, verify:

    line 224
  20. Very specific:

    If any resolved item is missing its closing keyword (or only appears under Refs), regenerate the body before creating the PR.

    line 228
  21. Distinctive:

    Use the platform-appropriate tool:

    line 231
  22. Distinctive:

    After creating the PR, ask about reviewers:

    line 241
  23. Very specific:

    If the user chooses [Y] or provides names, use github/update_pull_request with the reviewers field to assign.

    line 253
  24. Distinctive:

    After PR creation, check the status of checks:

    line 257
  25. Very specific:

    If there are failures, use github/get_job_logs (if available) to fetch logs from failed jobs and present a diagnosis.

    line 265
  26. Very specific:

    If the project uses GitHub Copilot, offer automated review via github/request_copilot_review(owner, repo, pullNumber).

    line 280
  27. Very specific:

    If the PR is behind the base branch, offer update via github/update_pull_request_branch(owner, repo, pullNumber).

    line 284
  28. Distinctive:

    If CI passed and reviews were approved, offer merge with options: squash, rebase, or merge commit.

    line 288
  29. Very specific:

    If confirmed, use github/merge_pull_request(owner, repo, pullNumber, merge_method: "<choice>").

    line 290

“Common” is measured: kept by at least 6 in 10 of the 45 edited versions of this file we could read. “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

Pull Request — Implementation Finalization

Check Git State

Use read/changes to list source control changes. In addition:

git status
git diff --stat

Commit

If there are uncommitted changes, use the git-commit skill to commit.

Integration Branch Guard

Before pushing or creating a PR, verify the current branch is not the integration branch:

CURRENT_BRANCH=$(git branch --show-current)

Resolve the integration branch in this order:

  1. Integration Branch from .memory/git-config.md (if it exists)
  2. Repository default branch via git symbolic-ref refs/remotes/origin/HEAD
  3. Fallback: match against main, master, or develop

If the current branch matches the integration branch, stop and offer recovery:

You are on `[branch]`, which is the integration branch. A PR cannot be created from the integration branch to itself, and pushing directly bypasses code review.

[B] Create a feature branch from the current commit(s) and open a PR (recommended)
[P] Push directly to [branch] (not recommended, bypasses code review)

If the user chooses [B]:

Current stateRecovery action
Committed locally, not pushedCreate feature branch at HEAD, then reset integration branch to origin/[branch]: git branch <feature-branch>, git reset --hard origin/[branch], git checkout <feature-branch>. Confirm with the user before resetting.
Already pushed to integration branchCreate feature branch from the offending commit(s), push it, offer to revert the commit on the integration branch, then open PR from the feature branch.

If the user chooses [P], proceed with the push. Log the override decision.

This guard applies to both the PR creation path and the Push Only path below.

Offer PR Creation

If the automated review was already executed by devsquad.implement (step 9 of the orchestration flow), do not re-execute review. Use the result already obtained.

Implementation completed and committed.

Would you like me to open a Pull Request?

[Y] Yes, open PR
[R] Review implementation before PR (recommended for medium/high impact)
[N] No, just push

If the user chooses [R] and the automated review was already executed, present the existing result instead of re-executing.

Automated Reviews (sub-agents)

The type of review depends on the task's impact. Security review is delegated to devsquad.review when it is invoked — both never run separately.

High impact: Implementation Review (includes security)

Triggers (any of):

  • Task classified as high impact
  • Multiple user stories affected
  • Changes to public API or schema

Execute devsquad.review as a sub-agent. Pass the feature, task, and modified files.

High impact task. Running independent review...

After sub-agent result:

  • PASSED: Proceed with PR.
  • PASSED_WITH_FINDINGS: Present findings and ask if they want to fix now or proceed (findings are recorded in the review log).
  • FAILED: Do not proceed with PR. Present critical findings and offer to fix or escalate for spec/plan review.

Medium/low impact: Direct Security Review

When devsquad.review is not invoked automatically, assess if a security review is needed by evaluating the security triggers defined in devsquad.security (Authentication/Authorization, Sensitive data, External input, Persistence, Integrations).

If a trigger is detected, execute devsquad.security as a sub-agent in code mode.

After the result, present the verdict (PASSED / PASSED_WITH_FINDINGS / FAILED) following the same format above.

If no trigger is detected, proceed with PR.

Summary: who runs what

ImpactReviewSecurity
Highdevsquad.review (auto)Delegated by devsquad.review internally
Medium/Low + security triggerNo (available via [R])devsquad.security direct
Medium/Low without triggerNo (available via [R])No

Record Technical Debt

If during implementation you find problematic code outside the scope of the current task, record it as a work item.

SignalExample
Existing TODO/FIXME/HACK comments// TODO: refactor this
Significant duplicationSame logic in 3+ places
Excessive couplingChange in one module requires changes in several others
Code without tests in critical areaBusiness logic without coverage
Outdated dependency with vulnerabilityPackage with known CVE

Ask the user:

I identified technical debt outside the scope of this task:

[problem description]
Files: [list]
Suggested severity: [high/medium/low]

[C] Create tech debt work item on the board
[I] Ignore (do not record)

If confirmed, create the work item following the work-item-creation skill (Tech Debt section).

Determine Target Branch

Before creating the PR, determine the target branch:

cat .memory/git-config.md 2>/dev/null

Use Integration Branch from the config. If it doesn't exist, use the repository's default branch.

Create Pull Request

Detect Platform

Read .memory/board-config.md to determine the repo platform. If it contains Platform: azure-devops or the git remote points to dev.azure.com or visualstudio.com, use ADO tools. Otherwise use GitHub tools.

Check for Existing PR

# GitHub
github/list_pull_requests(owner, repo, head: "<owner>:<branch>", state: "open")

# Azure DevOps
ado/repo_pull_request(action: "list", status: "active", sourceRefName: "refs/heads/<branch>")

If an open PR already exists, inform and ask if they want to update the existing one.

Push the branch:

git push -u origin <branch-name>

Create PR with:

  • Title: Based on the main issue/task
  • Body:
    ## Description
    
    [Summary of what was implemented]
    
    ## Related issue
    
    Closes #[number]
    
    ## Changes
    
    - [list of main changes]
    
    ## Checklist
    
    - [ ] Tests passing
    - [ ] Code follows project standards
    - [ ] Documentation updated (if needed)

Closing keyword rules (do not skip)

The PR body must include one of GitHub's recognized closing keywords on its own line for every work item the PR fully resolves. Only these keywords trigger automatic close on merge: close, closes, closed, fix, fixes, fixed, resolve, resolves, resolved. Refs #N and See #N are read-only and do not close anything.

SituationUseExample
PR fully implements/resolves a tracked task, story, bug, or spikeCloses #N (one per resolved item, on its own line)Closes #11
PR contributes to a parent feature, epic, or related issue but does not close itRefs #NRefs #1
PR partially addresses an issue and intentionally leaves follow-upRefs #N plus a "Remaining work" note in the bodyRefs #11 + Remaining: …

Examples that work and examples that silently break:

# Works (issues #11 and #29 auto-close on merge; #1 stays open as parent)
Closes #11
Closes #29
Refs #1

# Silently broken (#11 and #29 stay open)
Refs #11 #29 #1

Spike PRs are not exempt: if the spike's deliverable is complete, Closes #<spike> is required. Use Refs only when the spike is intentionally incomplete and the issue should remain open for follow-up.

Pre-flight check

Before calling github/create_pull_request or ado/repo_pull_request_write, verify:

  1. Identify every work item the PR resolves (typically: the task or story the implementation was started from, plus any sub-issues fully delivered in this branch).
  2. For each resolved item, confirm a Closes #N, Fixes #N, or Resolves #N line exists on its own line in the body.
  3. If any resolved item is missing its closing keyword (or only appears under Refs), regenerate the body before creating the PR.
  • Labels: Inherit labels from the issue (feature, priority, etc.)

Use the platform-appropriate tool:

# GitHub
github/create_pull_request(owner, repo, title, body, head: "<branch>", base: "<target>")

# Azure DevOps
ado/repo_pull_request_write(action: "create", title, description, sourceRefName: "refs/heads/<branch>", targetRefName: "refs/heads/<target>")

After creating the PR, ask about reviewers:

Pull Request created: [link]

Would you like to assign reviewers?

[Y] Yes, suggest (search repo members)
[N] No, I'll request review manually
[name] Assign directly to: _

If the user chooses [Y] or provides names, use github/update_pull_request with the reviewers field to assign.

Check CI (post-creation)

After PR creation, check the status of checks:

github/pull_request_read(owner, repo, pullNumber, method: "get_check_runs")

Report summarized check status (passed / failed / pending).

If there are failures, use github/get_job_logs (if available) to fetch logs from failed jobs and present a diagnosis.

Report:

Pull Request created: [link]

Branch: [branch] -> [integration-branch]
Issue: Closes #[number]
Reviewers: [list or "none assigned"]
CI: [summarized status]

Request Copilot Review (optional)

If the project uses GitHub Copilot, offer automated review via github/request_copilot_review(owner, repo, pullNumber).

Update PR Branch

If the PR is behind the base branch, offer update via github/update_pull_request_branch(owner, repo, pullNumber).

Merge PR

If CI passed and reviews were approved, offer merge with options: squash, rebase, or merge commit.

If confirmed, use github/merge_pull_request(owner, repo, pullNumber, merge_method: "<choice>").

Push Only (no PR)

The Integration Branch Guard (above) must pass before pushing. If the current branch is the integration branch, the guard offers recovery options before reaching this step.

git push -u origin <branch-name>

Inform that the PR can be opened later by invoking the skill again.

Common Rationalizations

RationalizationReality
"It works in staging, it will work in production"Production has different data, traffic patterns, and edge cases. Monitor after deploy.
"We do not need feature flags for this"Every non-trivial feature benefits from a kill switch. Even "simple" changes can break things.
"Monitoring is overhead"Not having monitoring means discovering problems from user complaints instead of dashboards.
"The review is a formality"Reviews that rubber-stamp changes miss bugs, security issues, and architectural drift.
"Rolling back is admitting failure"Rolling back is responsible engineering. Shipping a broken feature to users is the failure.

Download now (ZIP)

  • Other versions50 projects use a version of this.

    Word for word · 0

    None found.

    Edited · 0

    None found.

    Wrote their own version · 50

    1. samchon/typia★ 5.9ksame name
    2. epicenter-md/epicenter★ 4.8ksame name
    3. EpicenterHQ/epicenter★ 4.8ksame name
    4. werf/werf★ 4.7ksame name
    5. basicmachines-co/basic-memory★ 4.4ksame name
    6. PaulWoitaschek/Voice★ 3.2ksame name
    7. heyitsnoah/claudesidian★ 2.6ksame name
    8. samchon/nestia★ 2.2ksame name
    9. theopenco/llmgateway★ 1.7ksame name
    10. microsoft/hve-core★ 1.6ksame name

    40 more not listed

    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.

  • Used alongsideProjects with it also use issue-campaign, development and 9 more.

    Other files people use alongside this one.

    Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
    • samchonSkill

      issue-campaign

      Defines the default solo repository-wide issue campaign for typia: exhaustive discovery, lead-vetted issue publication, one unified CI-validated implementation pull request per cycle, solo Self-Review, and repeated rediscovery until a full clean round. Use for broad audits, many issue candidates, or repeated issue-to-pull-request campaigns unless the user explicitly requests parallel or multi-agent execution; do not use for one already-defined issue or an ordinary pull request.

      Also in 3 projects that use this

    • mfang0126Skill

      development

      Full-stack development workflow skill. Guides the complete cycle from understanding requirements to shipping code via PR with Preview validation.

      Also in 3 projects that use this

    • AnthropicSkill

      contracts

      Answer a question across a corpus of contract documents with verified citations. Use when the user asks what a contract says, which contracts have a clause, what changed between amendments, or any question that needs reading and citing across a set of contract files. The corpus must be on the local filesystem (see README).

      Also in 3 projects that use this

    • dragonflydbSkill

      benchmark

      Benchmark Dragonfly (and compare against Valkey/Redis) on local or remote cloud instances, then produce a performance + memory report with charts and a raw-data appendix. Use this whenever the user runs /benchmark, or asks to benchmark / load-test / measure throughput, QPS, latency, or memory efficiency of Dragonfly or another Redis-compatible server, to compare Dragonfly vs Valkey or Redis, or to generate a benchmark report. Trigger it even when the user just describes the goal ("see how fast Dragonfly is on this box", "compare memory per key vs Valkey") without saying the word "benchmark".

      Also in 4 projects that use this

    • NVIDIASkill

      testing

      Run Python and Rust tests for physicsnemo-curator using uv + pytest with coverage reporting via pytest-cov, and cargo-nextest for Rust tests. Includes benchmark workflows with pytest-benchmark and criterion.

      Also in 6 projects that use this

    • GoogleSkill

      prototype

      Build a throwaway prototype to answer a design question. Use when the user wants to sanity-check whether a state model or logic feels right, or explore what a UI should look like.

      Also in 5 projects that use this

  • In this repository26 other files it gives its agents.

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.