core.editor

The setting that names the text editor Git opens for commit messages and other text you need to write.

In more detail

If it is unset Git uses the EDITOR environment variable or falls back to vi. Graphical editors need a flag that makes the command wait until you close the file, as in code --wait for Visual Studio Code.

Example

git config --global core.editor 'code --wait'

Related terms

Taught in

References