DevTools
[Git] git merge Already up to date 문제
zhye
2021. 8. 17. 15:55
반응형
master의 코드를 내 브랜치로 병합하고 싶을 때,
분명 master가 변경되었음에도 불구하고 아래 사진처럼 Already up to date라는 문구가 뜰 때가 있다.
이 때는 merge가 아닌 pull 명령어로 가져오면 가끔 해결이 된다.
+ git pull로 원격 저장소의 코드를 가져올 때에도 Already up to date 문구가 뜰 때가 있는데,
$ git fetch --all
$ git reset --hard origin/master
그럴 땐 위 명령어로 원격 저장소를 모두 fetch한 후
해당 브랜치로 강제로 리셋시키면 된다는 정보를 알게 되었다.
git repo says it's up-to-date after pull but files are not updated
I have 3 repos. A bare repo which I use as a master repo, a dev repo in which I make and test changes, and prod repo from which scripts are executed in the prod environment. After I have tested ch...
stackoverflow.com
하지만 이 방법은 현재 로컬의 작업내역이 날라갈 수 있다는 위험성이 있다ㅜ
반응형