Agent skill

PR Local Preview Maintainer

by Undertone0809 in Undertone0809/rudder

A skill your agent uses when checking out, running, previewing, reviewing, or validating a GitHub pull request locally in a safe worktree, including PR preview URLs, local screenshots, readiness…

Apache-2.0Auto-check passedDevelopment

Install PR Local Preview Maintainer

skills CLI
$ npx skills add Undertone0809/rudder --skill pr-local-preview-maintainer -a claude-code

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

GitHub CLI
$ gh skill install Undertone0809/rudder pr-local-preview-maintainer --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/Undertone0809/rudder.git skills-src && mkdir -p .claude/skills && cp -r skills-src/agent-skills-bak/maintainer/pr-local-preview-maintainer .claude/skills/pr-local-preview-maintainer && 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
pr-local-preview-maintainer
GitHub stars
292
Token cost
~1.6k tokens
SKILL.md length
694 words
Files
2 (incl. references)
Skills in repo
30
Repo updated
First seen
Licence
Apache-2.0

At a glance

A skill your agent uses when checking out, running, previewing, reviewing, or validating a GitHub pull request locally in a safe worktree, including PR preview URLs, local screenshots, readiness…

  • Works in 8 steps: Preserve the current workspace → Check out the PR in the worktree → Install dependencies only when needed → …
  • Validating a GitHub pull request locally in a safe worktree
  • SKILL.md covers Default Workflow, Cleanup Requests and Safety Notes
  • Calls git, gh and pnpm

What it does

PR Local Preview Maintainer is an agent skill from Undertone0809/rudder. Use when checking out, running, previewing, reviewing, or validating a GitHub pull request locally in a safe worktree, including PR preview URLs, local screenshots, readiness checks, logs, and cleanup instructions.

Its SKILL.md is about 1.6k tokens, which your agent loads only when the skill is triggered. The skill folder holds 2 other files, including reference files (for example `references/runbook.md`).

It sits in Development, covering Git worktrees. It works with GitHub. The repository describes itself as: Open-source local Agent harness for self-improving agent teams: run agents, review work, and turn feedback into reusable skills. The licence is Apache-2.0.

When your agent uses it

  • Validating a GitHub pull request locally in a safe worktree
  • Including PR preview URLs
  • Local screenshots
  • Readiness checks

Example prompts

  • “/pr-local-preview-maintainer”

Workflow steps

8 steps, taken from the step headings in SKILL.md.

  1. Preserve the current workspace
  2. Check out the PR in the worktree
  3. Install dependencies only when needed
  4. Choose isolated runtime settings
  5. Start the preview so it survives hand-off
  6. Wait for readiness
  7. Decide whether UI screenshots are required
  8. Hand-off format

What it can do on your machine

Read from SKILL.md and the folder at commit e2ba0f1. 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:

    • git
    • gh
    • pnpm
    • curl

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

  • Network

    No URLs in SKILL.md. Its commands use git, gh, pnpm and curl, 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

PR Local Preview Maintainer loads about 1.6k tokens when it runs, and up to ~3.1k if it reads all its reference files. Until then it costs about 61 tokens; SKILL.md has 694 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~61
When it runs · the whole SKILL.md, loaded when a task matches
~1.6k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~3.1k

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 Undertone0809/rudder at commit e2ba0f1, republished under its Apache-2.0 licence (© Undertone0809). 694 words, ~1,560 tokens.

Download SKILL.mdSave it as .claude/skills/pr-local-preview-maintainer/SKILL.md (or your agent's skills folder). This skill also uses 1 other file; get the full folder from GitHub.
name
pr-local-preview-maintainer
description
Use when checking out, running, previewing, reviewing, or validating a GitHub pull request locally in a safe worktree, including PR preview URLs, local screenshots, readiness checks, logs, and cleanup instructions.

PR Local Preview Maintainer

Run pull requests in a disposable local worktree and give the user a stable preview link. The point is to let the user review the PR while protecting their current working tree and making UI changes visible.

Default Workflow

1. Preserve the current workspace

Start by checking the repository state:

bash
git status --short --branch
gh pr view <number> --json number,title,state,headRefName,headRepositoryOwner,url,isCrossRepository

If the current worktree has local changes, do not run gh pr checkout there. Create or reuse a sibling worktree instead. This avoids overwriting unrelated work and keeps the PR preview easy to remove later.

Use a predictable path:

text
<repo-parent>/<repo-name>-pr-<number>

For this repository, PR 8 should become:

text
/Users/zeeland/projects/rudder-oss-pr-8

If the directory already exists, inspect it before reusing it:

bash
git -C <worktree-path> status --short --branch
git -C <worktree-path> branch --show-current

If it is dirty, ask only if the dirty changes conflict with the user's goal. Otherwise, pick a suffixed path such as <repo-name>-pr-<number>-preview.

2. Check out the PR in the worktree

Create the worktree from the remote base, then check out the PR branch inside it:

bash
git worktree add --detach <worktree-path> origin/main
gh pr checkout <number> --branch zeelandc/pr-<number>

If main is not the base branch, use the PR's actual base ref. Prefer a local branch name that makes the preview purpose clear and follows the user's branch prefix convention when the repository defines one.

After checkout, verify:

bash
git status --short --branch
3. Install dependencies only when needed

Check whether dependencies are present:

bash
test -d node_modules && echo node_modules-present || echo node_modules-missing

If missing, install them from the worktree:

bash
pnpm install

Report install warnings only when they affect the preview. Routine peer or bin link warnings can be mentioned briefly.

4. Choose isolated runtime settings

Before starting, inspect occupied ports and existing local runtimes:

bash
lsof -nP -iTCP:<candidate-port> -sTCP:LISTEN

For Rudder, prefer:

bash
RUDDER_INSTANCE_ID=pr-<number>
PORT=<free-api-port>
RUDDER_EMBEDDED_POSTGRES_PORT=<free-pg-port>

Use 3100 only if it is free and the user clearly wants the default instance. If another Rudder dev runtime is already running, leave it alone and use a separate port and instance ID.

Example:

bash
env RUDDER_INSTANCE_ID=pr-8 PORT=3118 RUDDER_EMBEDDED_POSTGRES_PORT=54358 pnpm dev
5. Start the preview so it survives hand-off

Use tmux when available. It keeps the preview alive after the assistant turn ends and gives the user a simple way to inspect logs.

bash
tmux new-session -d -s rudder-pr-<number> -c <worktree-path> \
  'env RUDDER_INSTANCE_ID=pr-<number> PORT=<port> RUDDER_EMBEDDED_POSTGRES_PORT=<pg-port> pnpm dev'

If tmux is not available, use another managed background process and capture logs to /tmp/<repo-name>-pr-<number>.log. Do not leave an opaque process running without telling the user how to stop it.

6. Wait for readiness

Poll the health endpoint or the app's equivalent readiness check:

bash
curl -fsS http://127.0.0.1:<port>/api/health

If the app has no health endpoint, use the first meaningful route and check for a successful response. For frontend-only apps, load the dev server URL and confirm it serves HTML.

When startup fails, inspect the session logs before returning:

bash
tmux capture-pane -pt rudder-pr-<number> -S -160

Fix straightforward startup issues yourself when they are local environment problems, such as missing dependencies or port conflicts. Do not edit PR source code unless the user asked for a fix.

Show full SKILL.md (263 more words)Show less
7. Decide whether UI screenshots are required

Screenshots are required when any of these are true:

  • the PR title, files, or user request mentions UI, layout, pages, components, CSS, design, screenshots, visual review, browser behavior, or interaction
  • changed files live under ui/, desktop/, frontend route files, component directories, stylesheets, or public assets
  • the user says they want to "see" the effect

Use Browser Use for local browser inspection when available. Capture the important screen or flow after the preview is running. Store temporary screenshots outside the repository, for example:

text
/tmp/rudder-pr-<number>-<view>.png

For non-UI backend/API PRs, a health check plus a task-specific API smoke check is usually enough. If the user still needs to review manually, provide the URL.

8. Hand-off format

Keep the final response short and concrete:

text
PR <number> is running in <worktree-path>.

Open: http://127.0.0.1:<port>
Logs: tmux attach -t rudder-pr-<number>
Stop: tmux kill-session -t rudder-pr-<number>

Health check passed: <brief status>
Screenshots: <paths or embedded images when UI changed>

If screenshots were required but could not be captured, say exactly why and what verification did run.

Cleanup Requests

When the user asks to close, stop, or clean up the preview, stop only the PR preview session and verify its port is free:

bash
tmux kill-session -t rudder-pr-<number>
lsof -nP -iTCP:<port> -sTCP:LISTEN

Do not remove the worktree unless the user explicitly asks for cleanup. If they do ask to remove it, verify the worktree has no uncommitted changes first.

Safety Notes

  • Never use destructive Git commands in the user's main worktree to make a PR checkout succeed.
  • Do not stop unrelated Rudder dev sessions just because the default port is in use; choose an isolated port instead.
  • Keep PR preview data isolated with a dedicated RUDDER_INSTANCE_ID.
  • If source edits become necessary, pause and state that the task has shifted from previewing a PR to fixing it.

© Undertone0809, 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

SKILL.md and 1 other file (references) in agent-skills-bak/maintainer/pr-local-preview-maintainer of Undertone0809/rudder.

  • SKILL.md
  • references/runbook.md

Open the folder on GitHubat commit e2ba0f1

Compare with similar skills

PR Local Preview Maintainer 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.

PR Local Preview Maintainer compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
PR Local Preview Maintainer this skillUndertone0809/rudder292—~1.6kAutomated safety check: PassApache-2.0
Pre-Release PR Triagejamiepine/voicebox57k—~3.1kAutomated safety check: PassMIT
Codewhale Landing Workflowcodewhale-hq/Codewhale41k—~1.6kAutomated safety check: PassMIT
Ff Worktreesdamus-io/damus2.1k—~451Automated safety check: PassGPL-3.0
Clean Complete Branchesjtenniswood/espcontrol1.1k—~820Automated safety check: PassCustom licence
Clean Merged Branch Foldersjtenniswood/espcontrol1.1k—~813Automated safety check: PassCustom licence

Similar skills

  • Pre-Release PR Triage

    jamiepine/voicebox

    Sorts a backlog of open pull requests into must-merge, candidate, superseded and deferred, writes a triage doc and works the merge loop before a release.

    57k GitHub stars~3.1k tokensUpdated 2 days ago
    DevelopmentAuto-check passed
  • Codewhale Landing Workflow

    codewhale-hq/Codewhale

    Decides how verified work should reach main, directly, in a worktree or on an integration branch, while keeping contributor credit and respecting merge gates.

    41k GitHub stars~1.6k tokensUpdated today
    DevelopmentAuto-check passed
  • Ff Worktrees

    damus-io/damus

    Fast-forward master and every git worktree branch up to a target ref (default github/master), skipping any worktree with unmerged commits.

    2.1k GitHub stars~451 tokensUpdated 27 days ago
    DevelopmentAuto-check passed
  • Clean Complete Branches

    jtenniswood/espcontrol

    Clean up completed Git branches and worktrees for this repository both locally and on GitHub.

    1.1k GitHub stars~820 tokensUpdated today
    DevelopmentAuto-check passed
  • Clean Merged Branch Folders

    jtenniswood/espcontrol

    Clean up local branch worktree folders for this repository after their branches or pull requests have merged to main.

    1.1k GitHub stars~813 tokensUpdated today
    DevelopmentAuto-check passed
  • Fix

    exercism/website

    Fix a GitHub issue end-to-end — fetches issue, creates worktree, plans and implements fix, runs validation, opens PR, cleans up.

    549 GitHub stars~1.2k tokensUpdated yesterday
    DevelopmentAuto-check: notes

More from Undertone0809/rudder

All 30 skills in this repo
  • Conversation To Skill

    Undertone0809/rudder

    Turn the current conversation's workflow into a reusable agent skill.

    292 GitHub stars~3.6k tokensUpdated today
    Auto-check passed
  • A skill your agent uses when starting the current Rudder checkout as a temporary managed local preview with a stable URL, readiness check, logs, stop command, and cleanup path for manual inspection…

    292 GitHub stars~2.1k tokensUpdated today
    Auto-check passed
  • Stop Rudder Dev Maintainer

    Undertone0809/rudder

    A skill your agent uses when the user explicitly asks to stop, restart, kill, or clean Rudder repo-local pnpm dev processes or local dev runtime residue, including “把 pnpm dev 停了”, “重启 dev”, or “清掉…

    292 GitHub stars~1.3k tokensUpdated today
    Auto-check passed
  • Deep Research

    Undertone0809/rudder

    Conducts enterprise-grade research with multi-source synthesis, citation tracking, and verification.

    292 GitHub stars~1.2k tokensUpdated today
    Auto-check passed
  • A skill your agent uses to audit or clean Rudder worktrees, generated artifacts, logs, caches, and repo-owned processes without deleting active work, user data, or unrelated machine state.

    292 GitHub stars~664 tokensUpdated today
    Auto-check passed
  • Visualize

    Undertone0809/rudder

    Create safe inline visual explanations in Rudder Chat. An agent skill from Undertone0809/rudder.

    292 GitHub stars~1.8k tokensUpdated today
    Auto-check passed

Works with

Categories

Questions about PR Local Preview Maintainer

What does PR Local Preview Maintainer do?

A skill your agent uses when checking out, running, previewing, reviewing, or validating a GitHub pull request locally in a safe worktree, including PR preview URLs, local screenshots, readiness…. PR Local Preview Maintainer is an agent skill from Undertone0809/rudder. Use when checking out, running, previewing, reviewing, or validating a GitHub pull request locally in a safe worktree, including PR preview URLs, local screenshots, readiness checks, logs, and cleanup instructions.

When should I use PR Local Preview Maintainer?

PR Local Preview Maintainer fits situations like: validating a GitHub pull request locally in a safe worktree; including PR preview URLs; local screenshots; readiness checks.

How do I install PR Local Preview Maintainer in Claude Code?

Run `npx skills add Undertone0809/rudder --skill pr-local-preview-maintainer -a claude-code`. Or copy the skill folder (agent-skills-bak/maintainer/pr-local-preview-maintainer in Undertone0809/rudder) into .claude/skills/pr-local-preview-maintainer in your project. Claude Code loads it when a task matches its description.

How do I install PR Local Preview Maintainer in Codex?

Run `npx skills add Undertone0809/rudder --skill pr-local-preview-maintainer -a codex`. Or copy the skill folder (agent-skills-bak/maintainer/pr-local-preview-maintainer in Undertone0809/rudder) into .agents/skills/pr-local-preview-maintainer in your project. Codex loads it when a task matches its description.

Can I use PR Local Preview Maintainer 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 Undertone0809/rudder --skill pr-local-preview-maintainer -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/pr-local-preview-maintainer, .gemini/skills/pr-local-preview-maintainer, .github/skills/pr-local-preview-maintainer and .opencode/skills/pr-local-preview-maintainer in your project.

What does PR Local Preview Maintainer need to run?

Going by SKILL.md and its folder, PR Local Preview Maintainer needs the command-line tools its instructions call (git, gh, pnpm and curl).

Does PR Local Preview Maintainer access the network?

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

Is PR Local Preview Maintainer 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 PR Local Preview Maintainer use?

PR Local Preview Maintainer 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 PR Local Preview Maintainer use?

About 1.6k tokens (SKILL.md is roughly 6.2k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 1.5k tokens, read only when the agent opens those files.

What are the alternatives to PR Local Preview Maintainer?

Skills that share tags, products or a category with PR Local Preview Maintainer: Pre-Release PR Triage (jamiepine/voicebox, 57k stars), Codewhale Landing Workflow (codewhale-hq/Codewhale, 41k stars), Ff Worktrees (damus-io/damus, 2.1k stars) and Clean Complete Branches (jtenniswood/espcontrol, 1.1k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains PR Local Preview Maintainer?

Undertone0809 (a GitHub user) maintains it in Undertone0809/rudder, which has 292 GitHub stars. The repository holds 30 skills in this directory. The repository was last updated on October 9, 2026.

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