Skip to content
Development
Command

/deploy-info

Show what will deploy next — diff staging vs main with issue/PR summary, risk assessment, and deploy checklist

BOOST
From plugin
forgedock
11980 skills80 commands
Install
> /plugin marketplace add RapierCraftStudios/ForgeDock
> /plugin install forgedock@forgedock

How it fires

How this command gets triggered: by you, by Claude, or both.

  • Fires itselfClaude auto-loads it when your prompt matches the work.
  • You can call itInvoke it directly when you want it.
  • Slash command/deploy-info

Context preview

What this command does when you run it.

Show what will deploy next — diff staging vs main with issue/PR summary, risk assessment, and deploy checklist

Command definition

deploy-info.md
description: Show what will deploy next — diff staging vs main with issue/PR summary, risk assessment, and deploy checklist
argument-hint: "[staging | milestone/{slug} | compare {branch}]"
install: extras

/deploy-info — Pre-Deploy Summary

**Input**: $ARGUMENTS (default: `staging`)

**Config variables used by this command** (set in `forge.yaml`):

  • `{REPO_PATH}` ← `paths.root` — project repository root
  • `{HEALTH_ENDPOINT}` ← `services.health_endpoint` (optional) — URL used in post-deploy health check
  • `{DEPLOY_WORKFLOW}` ← `deploy.workflow` (optional) — GitHub Actions workflow filename to trigger a deploy (e.g., `hotfix-deploy.yml`). When absent or empty, workflow-trigger steps are omitted.
  • `{DEPLOY_SECRETS_BACKEND}` ← `deploy.secrets_backend` (optional) — secrets delivery method (`sops`, `aws-sm`, `vault`, `ci-env`, `none`). Controls whether secret-chain checks run.

You are the pipeline's deploy awareness layer. Before the user merges staging → main (triggering CI/CD deployment), this command shows exactly what's going out: which PRs, which issues, what changed, and what risks exist.

**Agent model policy**: `model: "{DEFAULT_MODEL}"` — resolved from forge.yaml `agents.default_model`, else "sonnet" (standard tier). Fallback: `model: "opus"` if rate-limited. User can override with `--model <name>`. Feature gate: pass `effort` in Task/Skill spawns only on Claude Code >= 2.1.154.

**NEVER use plan mode (EnterPlanMode)** — it breaks execution context.

<!-- FORGE:SPEC_LOADED — deploy-info.md loaded and active. Agent is bound by this spec. -->

---

Phase 0: Review-Finding Readiness Check

**Purpose**: Surface open review-finding issues before the deploy workflow begins. Staging→main PRs that ship with open findings have a 50%+ failure rate — this check identifies the readiness gap at the earliest possible point. <!-- Added: forge#372 -->

**Non-blocking**: This phase emits a warning but does NOT block. Deploy-info is an informational tool. The authoritative gate is Phase 0A of `/review-pr-staging`.

cd {REPO_PATH}
git fetch origin main staging

SOURCE=${SOURCE_BRANCH:-staging}
TARGET=${TARGET_BRANCH:-main}

# Step 1: Find all PR numbers in the bundle (same logic as review-pr-staging Phase 0A)
BUNDLE_PRS=$(git log origin/$TARGET..origin/$SOURCE --oneline \
  | grep -oE '#[0-9]+' \
  | sort -u \
  | tr -d '#')

MERGE_PRS=$(git log origin/$TARGET..origin/$SOURCE --merges --oneline \
  | grep -oE 'pull request #[0-9]+' \
  | grep -oE '[0-9]+' \
  | sort -u)

ALL_PR_NUMBERS=$(echo "$BUNDLE_PRS $MERGE_PRS" | tr ' ' '\n' | sort -u | grep -E '^[0-9]+$')

if [ -z "$ALL_PR_NUMBERS" ]; then
  echo "ℹ️  No PRs detected in bundle — skipping review-finding readiness check."
else
  # Step 2: Check for open review-finding issues referencing each PR
  OPEN_FINDINGS_SUMMARY=""
  for pr_num in $ALL_PR_NUMBERS; do
    # Anchored post-filter (same as review-pr-staging.md): the search is a coarse candidate fetch only
    FINDING_PR_FILTER='[.[] | select((.title | endswith("PR #" + $n + ")")) or ((.body // "") | test("(^|\\n)\\*\\*Source\\*\\*: PR #" + $n + "([^0-9]|$)")))] | .[] | "  - #\(.number): \(.title)"'  # FINDING_PR_FILTER
    OPEN_FINDINGS=$(gh issue list -R {GH_REPO} \
      --label "review-finding" \
      --state open \
      --search "PR #${pr_num}" \
      --limit 20 \
      --json number,title,body 2>/dev/null \
      | jq -r --arg n "${pr_num}" "$FINDING_PR_FILTER" 2>/dev/null)  # uses FINDING_PR_FILTER

    if [ -n "$OPEN_FINDINGS" ]; then
      OPEN_FINDINGS_SUMMARY="${OPEN_FINDINGS_SUMMARY}
**PR #${pr_num}** has open review findings:
${OPEN_FINDINGS}"
    fi
  done

  # Step 3: Report readiness state
  if [ -n "$OPEN_FINDINGS_SUMMARY" ]; then
    echo ""
    echo "⚠️  READINESS WARNING — Open review-finding issues exist for PRs in this bundle."
    echo ""
    echo "$OPEN_FINDINGS_SUMMARY"
    echo ""
    echo "These findings will block deploy when /review-pr-staging runs (Phase 0A gate)."
    echo "Fix the open findings and merge fixes to staging before deploying."
    echo "Or post 'OVERRIDE: shipping with open findings — <reason>' on the staging→main PR to bypass."
    echo ""
    echo "READINESS: NOT READY — open findings present"
  else
    echo "✅ Review-finding readiness: READY — no open findings for PRs in this bundle."
  fi
fi

---

Phase 1: Resolve What to Compare

| Input | Source Branch | Target Branch | Scenario | |-------|--------------|---------------|----------| | `staging` or empty | `staging` | `main` | Normal fast-lane deploy | | `milestone/{slug}` | `milestone/{slug}` | `staging` | Ship milestone to staging | | `compare {branch}` | `{branch}` | `main` | Custom comparison |

cd {REPO_PATH}
git fetch origin main staging

# Determine source and target
SOURCE=${SOURCE_BRANCH:-staging}
TARGET=${TARGET_BRANCH:-main}

# Check if there are any differences
AHEAD=$(git rev-list --count origin/$TARGET..origin/$SOURCE)
if [ "$AHEAD" -eq 0 ]; then
  echo "✅ $SOURCE is up to date with $TARGET — nothing to deploy."
  exit 0
fi
echo "$AHEAD commits ahead"

---

Phase 2: Gather Deploy Payload

Step 2A: Commit log

# All commits that will deploy
git log --oneline origin/$TARGET..origin/$SOURCE --format="%h %s" | head -50

Step 2B: PRs included

# Extract PR numbers from merge commits
PR_NUMBERS=$(git log origin/$TARGET..origin/$SOURCE --merges --format="%s" | grep -oE '#[0-9]+' | sort -u)

# Get PR details
for PR in $PR_NUMBERS; do
  NUM=${PR#\#}
  gh pr view $NUM --json number,title,author,labels,mergedAt --jq '"\(.number) | \(.title) | \(.author.login) | \([.labels[].name] | join(","))"' 2>/dev/null
done

Step 2C: Issues being closed

# Extract issue references from PR bodies
for PR in $PR_NUMBERS; do
  NUM=${PR#\#}
  CLOSES=$(gh pr view $NUM --json body --jq '.body' 2>/dev/null | grep -oE 'Closes #[0-9]+' | grep -oE '[0-9]+')
  for ISSUE in $CLOSES; do
    gh issue view $ISSUE --json number,title,
Read more
Ships withforgedock

ForgeDock — autonomous AI dev pipeline for Claude Code. GitHub as agent memory: issue in, PR out.

Get the whole plugin

Other commands on forgedock.