Agent skill

update-graphite-stack

Update Graphite PR stacks by addressing review comments and syncing PRs. Use when user says "update my graphite stack", "address the review comments on my stack", "sync my PR stack after these changes", "submit my entire stack to Graphite", or "I need to update all the PRs in my stack".

Stars 30
Forks 9

Install this agent skill to your Project

npx add-skill https://github.com/Uniswap/ai-toolkit/tree/next/packages/plugins/development-pr-workflow/skills/update-graphite-stack

SKILL.md

Graphite Stack Updater

Automate Graphite PR stack updates by resolving comments and syncing PRs.

Note: This skill requires Graphite CLI (gt) as PR stacking is a Graphite-specific concept. For standard Git workflows, use the pr-issue-resolver skill to address PR comments on individual PRs.

When to Activate

  • User has a Graphite stack with comments
  • Multiple PRs need updating
  • Stack sync needed after changes
  • Review comments to address
  • User mentions "gt stack" or "update stack"

Prerequisites

  • Graphite CLI installed: npm install -g @withgraphite/graphite-cli@latest
  • Repository initialized with Graphite: gt repo init
  • Existing Graphite stack with PRs to update

Why Graphite-only? This skill manages PR stacks, which is a Graphite-specific workflow. For standard Git workflows, use pr-issue-resolver to address comments on individual PRs.

What It Does

  1. Analyze Stack: Check structure with gt stack
  2. Find Comments: Identify PRs with unresolved feedback
  3. Address Feedback: Help resolve comments
  4. Update Stack: Use Graphite commands to sync
  5. Verify: Ensure all upstack PRs remain in sync

Execution Flow

For each PR with comments (bottom to top):

  1. Review the feedback
  2. Make necessary changes
  3. Run gt modify --no-verify to amend
  4. Execute gt submit --stack --update-only to sync upstack
  5. Continue until all PRs updated

Key Graphite Commands Used

bash
gt stack           # View current stack
gt modify          # Amend current commit
gt submit --stack  # Update all PRs in stack

Options

  • Process entire stack or specific PR range
  • Filter by comment type (style, logic, performance)
  • Dry-run mode to preview changes
  • Auto-commit vs manual review mode

Output

Progress summary with:

  • Number of PRs updated
  • Comments resolved per PR
  • Remaining unresolved items
  • Stack synchronization status

Optional Follow-up

After updates, can invoke refactorer-agent to verify changes maintain quality.

Examples

"Update my graphite stack"
"Address the review comments on my stack"
"Sync the stack starting from PR #123"

Expand your agent's capabilities with these related and highly-rated skills.

Uniswap/ai-toolkit

review-plan

Review implementation plans for completeness and feasibility. Use when user says "review this plan before I start", "is this implementation plan complete", "check if this plan aligns with our patterns", "give me feedback on my implementation strategy", or "validate this plan before we execute it".

30 9
Explore
Uniswap/ai-toolkit

plan-implementation

Create implementation plans for features and changes. Use when user says "plan how to implement user authentication", "how should I add dark mode to the app", "what's the best way to refactor the database layer", "create a plan for migrating to the new API", or "I need to implement [feature] - help me plan it out".

30 9
Explore
Uniswap/ai-toolkit

execute-plan

Execute implementation plans step-by-step. Use when user says "execute the plan", "implement the plan we created", "start building based on the plan", "go ahead and implement it", "proceed with the implementation", "execute as a stack", "create a PR stack while implementing", "implement with one PR per step", or references a plan file and wants to begin coding.

30 9
Explore
Uniswap/ai-toolkit

generate-commit-message

Generate well-structured git commit messages. Use when user says "generate commit message", "write a commit", "what should my commit message be", "create commit message for these changes", or needs help crafting conventional commit messages.

30 9
Explore
Uniswap/ai-toolkit

plan-swarm

Refine plans through multi-agent expert discussion. Use when user says "get multiple expert opinions on this plan", "I want different perspectives on this approach", "have the agents discuss this strategy", "refine the plan through collaborative review", or "what would different specialists think about this design".

30 9
Explore
Uniswap/ai-toolkit

create-pr

Create or update pull requests with conventional commits. Use when user says "create a PR for these changes", "submit this for review", "open a pull request", "push these changes and create a PR", "I'm ready to submit this work", or "create PR and link to issue

30 9
Explore

Didn't find tool you were looking for?

Be as detailed as possible for better results