DEV Community

olistik
olistik

Posted on

VS Code shell variables and git

I use zshell so in order to persist my choice I edit ~/.zprofile:

export EDITOR="code --new-window"

When commiting from the command line (git commit) we have to make the editor wait for us to finish the commit message and therefore we need to instruct git use the --wait option too:

$ git config --global core.editor "code --wait --new-window"

This way the commit message will be taken by git right after we issue a save command.

🎩

Top comments (0)