[Git] Please enter a commit message to explain why this merge is necessary, especially if it merges an updated upstream into a topic branch

2022. 1. 16. 14:50·Git & GitHub/오류해결

 

 

Git bash를 통해서 merge를 진행하거나 pull 명령어를 사용하면

# Please enter a commit message to explain why this merge is necessary,
# especially if it merges an updated upstream into a topic branch.
#
# Lines starting with '#' will be ignored, and an empty message aborts
# the commit

라고 적힌 까만 창이 뜨는데 아무것도 적히지도 않고

esc나 q를 눌러도 나가지지 않아서 굉장히 당황스러울 것이다.

키보드를 막누르다가 잘못 건드려서 로컬저장소에 문제가 생기면 어쩌나 하는 생각도 들 것이다.

이럴 때 간단히 빠져나갈 수 있는 방법이 있다.

 

 

 

 

  해결하기!  


1.  i  를 누른다  ==>  i 를 누르면  Insert 모드로 바뀌어서 merge message를 입력할 수 있다.

 

2. merge 메세지를 입력한다.

 

3.  esc  키를 누른다.  ==>  Insert 모드를 취소

 

4.  :wq  를 입력한다.

 

5.  enter  키를 누르면 끝!!

'Git & GitHub/오류해결' 카테고리의 다른 글
  • [오류해결] fatal: Unable to create '~~/.git/index.lock': File exists.
  • [오류해결][Git] merge Conflict 해결
  • [오류해결] fatal: The current branch master has no upstream branch.To push the current branch and set the remote as upstream
  • git push 오류가 생길 때 (부제: error: failed to push some refs to)
gakko
gakko
좌충우돌 개발기
  • gakko
    MYVELOP 마이벨롭
    gakko
  • 전체
    오늘
    어제
    • 분류 전체보기 (203)
      • Spring (23)
        • Spring (10)
        • Spring Boot (7)
        • Spring Security (1)
        • Hibernate (4)
      • Test (3)
      • 끄적끄적 (6)
      • 활동 (35)
        • 부스트캠프 (23)
        • 동아리 (3)
        • 컨퍼런스 (3)
        • 글또 (5)
        • 오픈소스 컨트리뷰션 (1)
      • 디자인패턴 (0)
      • Git & GitHub (22)
        • Git (13)
        • Github Actions (1)
        • 오류해결 (5)
        • 기타(마크다운 등) (3)
      • 리눅스 (6)
        • 기초 (6)
        • 리눅스 서버 구축하기 (0)
      • Infra (2)
        • Docker (1)
        • Elastic Search (0)
        • Jenkins (1)
        • AWS (1)
      • MySQL (7)
        • 기초 (6)
        • Real MySQL (1)
      • 후기 (3)
        • Udemy 리뷰 (3)
      • CS (26)
        • 웹 기본지식 (0)
        • 자료구조 (13)
        • 운영체제 OS (12)
        • 데이터베이스 (1)
        • 시스템 프로그래밍 (0)
        • 기타 (0)
      • Tools (1)
        • 이클립스 (1)
        • IntelliJ (0)
      • 프로젝트 (1)
        • 모여모여(부스트캠프) (1)
      • JAVA (32)
        • Maven (6)
        • 오류해결 (11)
        • 자바 클래스&메소드 (1)
        • JSP & Servlet (12)
      • Javascript (5)
        • 기초 (3)
        • React (2)
      • Python (28)
        • 파이썬 함수 (9)
        • 알고리즘 문제풀이 (16)
        • 데이터 사이언스 (2)
        • 웹 크롤링 (1)
      • 단순정보전달글 저장소 (0)
  • 블로그 메뉴

    • 홈
    • 태그
    • 방명록
  • 링크

    • 우진님
  • 공지사항

  • 인기 글

  • 태그

    스프링
    jsp
    알고리즘
    웹개발
    파이썬
    java
    Python
    GitHub
    Spring
    Git
    부스트캠프 7기
    스프링부트
    자바
    부스트캠프 멤버십
    os
    MySQL
    부스트캠프
    운영체제
    자바스크립트
    오류해결
  • 최근 댓글

  • hELLO· Designed By정상우.v4.10.0
gakko
[Git] Please enter a commit message to explain why this merge is necessary, especially if it merges an updated upstream into a topic branch
상단으로

티스토리툴바