오늘의 에러

김종원·2022년 6월 12일
0

[git]

목록 보기
6/9

깃에 커밋을 하고 git push origin master를 하니

! [rejected] master -> master (fetch first)
hint: Updates were rejected because the remote contains work that you do
hint: not have locally. This is usually caused by another repository pushing
hint: to the same ref. You may want to first integrate the remote changes
hint: (e.g., 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.

에러가 발생했습니다.

발생의 원인은 레포지토리를 README 파일이나 LICENSE파일과 같이 생성하면 발생한다고 합니다..

해결방법은 pull을 하면 알아서 fetch와 merge가 된다고 합니다.

그래서 git pull origin master를 하니 오류가 해결되었습니다!!

shallow clone

profile
발전하기위한 기록

0개의 댓글