프론트엔드 첫걸음

git commit 시 에디터 설정 - git config core.editor commands 본문

개발 공부/Git

git commit 시 에디터 설정 - git config core.editor commands

차정 2022. 7. 2. 21:22

git 편집기 설정

 

https://git-scm.com/book/en/v2/Appendix-C%3A-Git-Commands-Setup-and-Config

위 링크에서 자신이 사용할 편집기에 맞는 명령어를 찾아 터미널에 입력하면 된다.

 

 

맥 + vscode 사용자의 경우 

 

1. vscode에서 cmd+shift+p   code입력=> 설치

   PATH에 쉘 명령어 code 설치

 

 

2. 터미널에 git config --global core.editor "code --wait"  입력

 

 

그러면 git commit 할 때 vim 아니라 editor가 나온다.

파일에 입력하듯이 커밋메시지를 입력하고 저장하면 된다.