디폴트 브랜치를 main으로 했는데, 디렉토리에서 commit할 때 master로 체크아웃된 상태였다.
그 결과 main branch에 push되지 않고 master 브랜치가 따로 생성된 것을 확인했다.
compare and pull request 버튼이 떠서 눌러보면
"main and master are entirely different commit histories" 라고 뜬다.
따라서 강제로 브랜치를 옮기는 식으로 해결했다.
git checkout master
git branch main master -f
git checkout main
git push origin main -f
참고한 블로그 https://kim6394.tistory.com/254
'컴퓨터 > BASIS' 카테고리의 다른 글
맥 터미널에서 채널(channel)이 4인 이미지를 3으로 바꾸기 (0) | 2021.09.10 |
---|---|
[GitHub] Mac에서 git 사용하기 (0) | 2021.07.16 |
[Mac M1] iTerm2가 conda 명령어를 인식하게 하기 (0) | 2021.04.27 |
[Mac M1] miniforge와 개발환경 설정, konlpy (0) | 2021.04.26 |
[GitHub] .gitignore 만들기 (0) | 2021.04.18 |