codestates / codestates/conimals

[정새얀] 220526 Error - Handling

Open
#38 0 comments 0 reactions 0 assignees View on GitHub
complete
Dominant language
JavaScript
Stars
3
Forks
5
PR merge metrics
No merged PRs in 30d

Description

> 해결된 에러라면 라벨에 'Complete' 를 달아주세요.
> 미해결된 에러라면 라벨을 'In progress' 로 변경해주세요.

### 어떤 에러인가요?
- git pull upstream dev 명령어 실행 시 fatal message가 뜨면서 pull이 제대로 되었는지 확인할 수 없는 상황.

### 에러 메시지

```bash
https://github.com/codestates/conimals URL에서
* branch dev -> FETCH_HEAD
힌트: You have divergent branches and need to specify how to reconcile them.
힌트: You can do so by running one of the following commands sometime before
힌트: your next pull:
힌트:
힌트: git config pull.rebase false # merge (the default strategy)
힌트: git config pull.rebase true # rebase
힌트: git config pull.ff only # fast-forward only
힌트:
힌트: You can replace "git config" with "git config --global" to set a default
힌트: preference for all repositories. You can also pass --rebase, --no-rebase,
힌트: or --ff-only on the command line to override the configured default per
힌트: invocation.
fatal: Need to specify how to reconcile divergent branches.
```

### 에러 핸들링 방법
구글링을 통해 git config pull.ff only 명령어를 사용하면 해결이 된다고 해서 그대로 실행해보고 pull을 해봤더니
fatal: 정방향이 불가능하므로, 중지합니다. 라는 메시지가 떴다.
git config --unset pull.ff 명령어로 기존에 실행했던 명령어를 취소시키고
소스트리를 이용하여 pull을 해온 다음 git config pull.rebase false 명령어를 사용했더니 해결이 되었다.
+ 22.06.15) 굳이 소스트리를 사용하여 pull을 해온 다음 명령어를 실행시키지 않고
git config pull.rebase false 명령어 사용 후 git pull 명령어를 실행했더니 정상적으로 pull을 할 수 있었다.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.