git push origin master 입력을 하였는데
error: src refspec master does not match any가 발생하였다.
원인:
깃허브에서 pull 없이 push할 경우에
기존 내용 삭제 문제가 생길 수 있기 때문.
해결방법:
git init
git add .
git commit -m "commit message"
git remote add origin "깃허브주소"
git push -u origin master
master 브팬치가 없어서 생기는 오류인 상황
git checkout -b 'master'
git push origin master
'기술블로그' 카테고리의 다른 글
Rest-API vs Graphql-API (0) | 2023.01.30 |
---|---|
git 명령어 및 실행 주의사항 (0) | 2023.01.30 |
타입스크립트 기초 실습 (0) | 2023.01.28 |
React기초 및 폴더구조와 Emotion (0) | 2023.01.27 |
Nodejs, npm, yarn (0) | 2023.01.27 |