stackblitz / webcontainer-core

Dev environments. In your web app.
https://webcontainers.io
MIT License
3.9k stars 165 forks source link

Running git commit --amend -s hangs the command line #920

Open sr229 opened 1 year ago

sr229 commented 1 year ago

Describe the bug

Any advanced git commands like amending will cause Git to enter a infinite loop state since it cannot invoke the editor. In Codespaces, this automatically opens a new tab in VSCode.

Link to the blitz that caused the error

https://stackblitz.com/~/github.com/sr229/metastruct-experiments

Steps to reproduce

Run the following commands:

$ git add .
$ git commit --amend -s

Expected behavior

Open a new tab or a CLI text editor

Parity with Local

Screenshots

image

Platform

Version = 1.67.0
Hash = cbdc3a8bd79af7e88b2855b67f4bf6f36ec8ebe5
WebContainer = 8cf5a3c77f45c942df800a39619ec49fff7e5814

Browser name  = Chrome
Full version  = 108.0.0.0
Major version = 108
navigator.appName = Netscape
navigator.userAgent = Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/108.0.0.0 Safari/537.36 Edg/108.0.1462.46
performance.memory = {
  "totalJSHeapSize": 158259044,
  "usedJSHeapSize": 137124804,
  "jsHeapSizeLimit": 2172649472
}

Additional context

No response

d3lm commented 1 year ago

Hey there 👋 Thanks for reporting this issue. We currently don't support --amend but are already tracking this internally. It's strange that it didn't throw. We'll keep you posted if there's progress.