Cross repo issues

From JeremyDev87/codingbuddy · View interactive version

Cross repo issues is an AI agent skill from the GitHub repository JeremyDev87/codingbuddy. Use when a bug or feature request belongs in an upstream, parent, or dependency repository rather than the current one. Guides detection, mapping, and safe cross-repo issue creation with user confirmation.

How to use this skill

Skill file

Cross-Repo Issue Creation

Overview

Not every issue belongs in the repository where it was discovered. Bugs in forked code belong upstream. Problems in a monorepo dependency belong in that dependency's repo. Filing issues in the wrong place wastes maintainer time and delays fixes.

Core principle: ALWAYS confirm the target repository with the user before creating an issue elsewhere. Never auto-create issues in repositories you don't own.

Iron Law:

NO CROSS-REPO ISSUE CREATION WITHOUT EXPLICIT USER CONFIRMATION

When to Use

Use this ESPECIALLY when:

When NOT to Use

Configuration

Add upstreamRepos to your codingbuddy.config.json:

{
  "upstreamRepos": {
    ".": "original-owner/original-repo",
    "packages/ui": "design-system/ui-kit",
    "dep:react": "facebook/react"
  }
}

Key Conventions

| Key Pattern | Meaning | Example |

|-------------|---------|---------|

| "." | Current repo is a fork of this upstream | "original-owner/repo" |

| "packages/..." | Monorepo package maps to external repo | "org/package-repo" |

| "dep:<name>" | npm/pip dependency maps to its source repo | "facebook/react" |

Minimal Configuration

For a simple fork, only one entry is needed:

{
  "upstreamRepos": {
    ".": "upstream-owner/upstream-repo"
  }
}

The Three Phases

Phase 1: Detect — Identify Where the Issue Belongs

Determine if the issue should go to another repository:

  1. Check the code origin
  1. Check the config mapping
  1. Verify the issue doesn't already exist upstream

Decision matrix:

| Scenario | Target Repo | Key |

|----------|-------------|-----|

| Bug in forked code | Upstream repo | "." |

| Bug in monorepo sub-package's upstream | Package source repo | "packages/<name>" |

| Bug in third-party dependency | Library repo | "dep:<package>" |

| Bug in your own code | Current repo (stop here) | N/A |

Completion criteria:

Phase 2: Confirm — Get User Approval

MANDATORY: Never skip this phase.

Present the following to the user before proceeding:

Cross-Repo Issue Detected:
  Source:  <current-repo> (<file-or-package>)
  Target:  <upstream-repo>
  Reason:  <why this belongs upstream>
  Title:   <proposed issue title>

Proceed with creating issue in <upstream-repo>? (y/n)

Include in the confirmation:

If user declines:

Completion criteria:

Phase 3: Create — File the Issue

Create the issue in the confirmed target repository:

  1. Format the issue body
## Description

<Clear description of the issue>

## Reproduction

- Repository: <your-repo> (discovered while working on <context>)
- File/Package: <affected file or package>
- Steps to reproduce: <steps>

## Expected Behavior

<what should happen>

## Actual Behavior

<what actually happens>

## Environment

- Version: <upstream version in use>
- OS: <if relevant>

## Additional Context

Discovered in downstream repo: <your-repo-url>
  1. Create the issue
gh issue create -R <owner/repo> \
  --title "<title>" \
  --body "<body>"
  1. Link back to current repo (optional)
gh issue create \
  --title "Tracking: <upstream-owner/repo>#<number>" \
  --body "Upstream issue: <url>\nBlocked until upstream fix is available." \
  --label "blocked-upstream"

Completion criteria:

Quick Reference

| Phase | Action | Verification |

|-------|--------|-------------|

| 1. Detect | Identify target repo from config or code origin | Target repo confirmed |

| 2. Confirm | Present plan to user, get explicit approval | User said yes |

| 3. Create | File issue via gh, link back if needed | Issue URL available |

Safety Checklist

Before creating any cross-repo issue:

Red Flags — STOP

| Thought | Reality |

|---------|---------|

| "I'll just create it, the user won't mind" | STOP. Always confirm. Cross-repo actions are visible to external maintainers. |

| "It's obviously an upstream bug" | Maybe. But confirm the target repo with the user first. |

| "I'll skip the duplicate check" | Duplicate issues waste maintainer time and hurt your credibility. |

| "The config mapping is enough confirmation" | Config maps repos, but the user must confirm each issue creation. |

| "I'll include our internal details for context" | STOP. Review for sensitive information before posting to external repos. |

| "No config? I'll guess the upstream repo" | Ask the user. Wrong repo = noise for unrelated maintainers. |

Examples

Fork → Upstream

Config: { "upstreamRepos": { ".": "expressjs/express" } }

Detected: Bug in request parsing (inherited from upstream)
Target:   expressjs/express
Action:   Confirm with user → Create issue in expressjs/express

Monorepo Package → Source Repo

Config: { "upstreamRepos": { "packages/icons": "design-org/icon-library" } }

Detected: Missing icon in packages/icons (sourced from design-org/icon-library)
Target:   design-org/icon-library
Action:   Confirm with user → Create issue in design-org/icon-library

Dependency → Library Repo

Config: { "upstreamRepos": { "dep:zod": "colinhacks/zod" } }

Detected: Validation bug in zod usage
Target:   colinhacks/zod
Action:   Confirm with user → Search existing issues → Create if new
Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.