Recent Posts
Recent Comments
목록git push 되돌리기 (1)
HEROJOON 블로그(히로블)
[Git] Git Remote의 특정 Commit Hash값 위치로 되돌리기
목표 원격 저장소(ex. Github)에 Push를 잘못했을 경우 Commit History에서 해당 내용을 제거하고 싶을 때가 있습니다. 이럴 경우 원하는 Commit HashCode(Commit ID) 시점으로 되돌릴 수 있습니다. 사용할 명령어 정리 # 원하는 Commit HashCode(Commit ID)로 되돌리기 # git reset --hard {Commit HashCode} git reset --hard 61204e63b3dae72f61712dd994a1da106212c36a # 위에서 설정한 내용 원격 저장소에 push # git push origin +{branch} # 여기서 +는 강제의 의미 git push origin +develop
Git
2020. 11. 26. 01:45