Skip to main content Link Menu Expand (external link) Document Search Copy Copied

Rebase시에 기존의 커밋 작성일 유지하기


--committer-date-is-author-date

git rebase를 통해 수정된 변경이력은 기존의 커밋들을 유지하는게 아니라 새로운 커밋을 만들어낸다. 이 때, 새로 생성된 커밋의 작성 시각은 rebase 한 시각으로 변경되는데,

git rebase B 명령을 실행했을 경우:

gitGraph
    commit id:"A"
    commit id:"B"
    branch rebased-branch

    checkout main
    commit id:"C"

    checkout rebased-branch
    commit id:"C'"

    checkout main
    commit id:"D"

    checkout rebased-branch
    commit id:"D'"

    checkout main
    commit id:" ..."

    checkout rebased-branch
    commit id:"..."


Back to top