github / github/copilot-cli

`/diff` branch mode: allow selecting the base branch

Aperta
#3,903 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub
area:tools
Lingua principale
Shell
Stelle
11.2k
Fork
1.9k
Merge medio
14h 16m
PR unite (30g)
6

Descrizione

### Describe the feature or problem you'd like to solve

When using  `/diff`  in branch mode, the base branch is auto-detected as the default branch of the tracking remote (e.g.,  `origin/main` ). There's no way to override this - if your branch was cut from something other than the default branch, the diff includes noise from the parent branch rather than just your changes.

### Proposed solution

Allow specifying a base branch when using branch diff mode - e.g., a text input when selecting "Branch diff", or a parameter like  `/diff base=feature/xyz` . This would let users diff against any branch, not just the remote default.

### Example prompts or workflows

- Working on a branch cut from `feature/parent` - want to see only changes since that branch, not since `main`
- Comparing work against a release branch rather than the repo default

### Additional context

_No response_

Guida per i contributori

Apri la guida per i contributori

Direzione di ricerca

Inizia dal punto di ingresso della modalità branch del comando `/diff` e segui il modo in cui seleziona il branch predefinito del remote di tracking. Aggiungi un modo per fornire un branch di base alternativo, quindi verifica che i diff tra branch vengano confrontati con il branch selezionato ed escludano le modifiche ereditate dal branch padre.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
git
Ambito
cli
Tipo di issue
Funzionalità
Difficoltà
3/5
Tempo stimato
1-2 giorni
Stato di attività
Tranquilla
Chiarezza
Abbastanza chiara
Idoneità per principianti
64/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.