<a href="https://stackoverflow.com/a/66309040" rel="nofollow">https://stackoverflow.com/a/66309040</a><p>This was the answer I originally linked to, because I found it to be an exceptional explanation of the inner workings of git. For some reason my submission now just links to the original question.