Skip to content

Code Cleanup and GIT mess clean-up

Bethe, T.M. (Timme, Student M-CS) requested to merge timme-dev into develop

Code changes: Added README and documentation

It has become clear to me that git is rather complicated and has 'gotchas', and I am not as adept at it as I thought I was.

I think this was the problem: A merge results into a new commit. It could be a fast-forward, but it does not have to be. Moreover, with gitlab merge requests, it is never a fast-forward. The action to merge, creates another commit. This is important.

Dramatic reenactment of what happened:

  • Create a branch feature, make changes and merge them into develop.
  • "naively assume that now both branches are at the same point" (THEY ARE NOT, develop has an extra commit because of the merge)
  • Continue committing in feature, which seems fine, because both have the same HEAD.
  • Try to merge these new changes, but be surprised it tells you the two branches have diverged. Huh, but I only ever made changes to the feature branch. confusion.
Edited by Bethe, T.M. (Timme, Student M-CS)

Merge request reports