The default editor for zsh is set to VS Code and it launches fine. However, it immediately somehow closes the session giving an empty editor window with the browser returning an error that it is not able to connect to the local host preview window.
I disabled all the workspace security settings in VS Code as well. Anyone have any idea why this could be happening or how it could be fixed?
I am not sure if you still have this issue or not, but I had the same issue and found a solution digging a bit deeper in the documentation though it wasn’t immediately apparent.
I had to open the Windows Environment Variables and create a new record of variable “GIT_EDITOR” and value “code”. Initially it did launch VS Code but closed right away like you stated. It was by looking closer at the documentation and changing my environment variable to “code --wait” that it wouldn’t immediately close (it would wait) until I choose to close the file. Hope that helps.