github / github/copilot-cli

Windows: Ctrl+G cannot launch code-insiders --wait

Offen
#3,733 1 Kommentar 1 Reaktion 0 zugewiesene Personen Auf GitHub ansehen
area:configuration area:platform-windows
Vorherrschende Sprache
Shell
Sterne
11.2k
Forks
1.9k
Ø Merge
14 Std. 16 Min.
Gemergte PRs (30 T.)
6

Beschreibung

### Bug

On Windows, `Ctrl+G` cannot launch VS Code Insiders when `$EDITOR` is set to the standard wait command:

```powershell
$env:EDITOR = 'code-insiders --wait'
```

The same command works directly from PowerShell.

### Repro

```powershell
$env:EDITOR = 'code-insiders --wait'
code-insiders --wait # works
copilot
# Press Ctrl+G
```

### Expected

Copilot CLI opens VS Code Insiders and waits for the prompt file to close.

### Actual

```text
✗ Error: Editor 'code-insiders --wait' not found. Check your $COPILOT_EDITOR, $VISUAL, or $EDITOR environment variable.
```

Using a `.cmd` wrapper also fails with `spawn EINVAL`.

### Notes

`code-insiders` resolves to a Windows `.cmd` shim, so this appears related to #1882. The fix is likely to handle Windows `.cmd` / `.bat` editor commands through `cmd /c` or `shell: true`, and to support editor commands with arguments such as `--wait`.

### Environment

- Windows
- PowerShell
- Copilot CLI 1.0.60
- VS Code Insiders

Beitragsleitfaden

Beitragsleitfaden öffnen

Rechercherichtung

Lesen Sie das zugehörige Issue #1882 und verfolgen Sie nach, wie die CLI Editor-Befehle unter Windows auflöst und startet. Reproduzieren Sie den PowerShell-Fall mit `code-insiders --wait` und dem `.cmd`-Wrapper und verifizieren Sie anschließend, dass der Editor geöffnet wird und auf das Schließen der Prompt-Datei wartet, ohne die gemeldeten Fehler.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
powershell, shell
Bereich
cli, operating-systems
Issue-Typ
Bug
Schwierigkeit
3/5
Geschätzter Aufwand
1-2 Tage
Aktivitätsstatus
Ruhig
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
56/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.