commit 에러

Jiwontwopunch·2021년 11월 15일
0

TIL

목록 보기
6/92
post-thumbnail

(계속 업데이트 중...)

Remote origin already exist

git remote remove origin
그리고 다시 
git remote add origin

fatal: unable to access '': Could not resolve host:www.github.com

git config --global --unset http.proxy
git config --global --unset https.proxy

error: The requested URL returned error: 401 Unauthorized while accessing

git버전 업그레이드 :  $ git update-git-for-windows

error: failed to push some refs to 'github.com:Jiwoncoding/mbti-page.git'

$ git push -f origin
커밋 강제 덮어쓰기 방법으로 권장하지는 않는다고 함 
아래의 방법으로 해결하는 걸 추천
1. 
$ git pull
만약 pull을 받을 때, 현재 브랜치위치가 master가 아닌
다른 브랜치인경우
> $ git pull 브랜치명

2. pull을 받은 후 push하면 remote의 코드가
local에 잘 반영되어 push될 것

commit은 성공했는데 잔디가 안심겨졌을경우

$ git config --list 
// 확인해보니 usernama과 email이 상이
수정하기위해서
$ git config --global user.name "홍길동"
$ git config --global user.email "support@webisfree.com"
$ git cinfig --list
// 수정한 username과 email. 

github 잔디에 private 레포 잔디심기

contribution settings에 Private contributions가
체크되어있어야함

error: 'practice/' does not have a commit checked out

해당 로컬 리포지토리 안의 다른 디렉토리(폴더)에
.git이 있기 때문에 발생하는 현상

1. add를 하고싶은 폴더를 연다
2. 숨김폴더를 볼 수 있게 한다
3. 1번 안에 있는 하위 폴더중 .git이 들어있는 폴더를 전부 찾는다.
4. 3번에서 찾은 git을 모두 삭제
5. 다시 add해본다.

github front-practice repository에 하위 폴더 graphql-server commit시 에러 발생

$ git push origin +master

폴더 삭제

$ git rm -rf (파일이나 폴더명)
$ git commit -m "delete folder"
$ git push -u origin +master

0개의 댓글