Bird
0
0

You tried to set your Git editor with git config core.editor code --wait but Git still opens Vim. What is the likely problem?

medium📝 Troubleshoot Q6 of 15
Git - Configuration and Aliases
You tried to set your Git editor with git config core.editor code --wait but Git still opens Vim. What is the likely problem?
AThe command missed quotes around the editor command, so only 'code' was set
BGit does not support Visual Studio Code as editor
CYou need to use --global flag to set the editor
DThe core.editor setting cannot include command options
Step-by-Step Solution
Solution:
  1. Step 1: Analyze the command syntax

    The command lacks quotes around code --wait, so Git interprets only code as the editor and ignores --wait.
  2. Step 2: Understand effect on editor behavior

    Without --wait, Git does not wait for VS Code to close and falls back to Vim.
  3. Final Answer:

    The command missed quotes around the editor command, so only 'code' was set -> Option A
  4. Quick Check:

    Quotes needed to include options in core.editor [OK]
Quick Trick: Always quote editor commands with spaces or options [OK]
Common Mistakes:
  • Not quoting multi-word editor commands
  • Assuming Git can't use VS Code
  • Forgetting to use --global when needed

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Git Quizzes