cd Programme/pc-git/ git status git pull pico README.md # change added git add README.md git commit -m "1st try" git status git pull # remote had a commit in between, therefore it did not work # automatically, a "Merge branch 'master'" commit got created, even though I did not want to. git status git log git switch c6c5265e4054805084f96ff796ed06326959fb26 git switch --detach c6c5265e4054805084f96ff796ed06326959fb26 git log git pull --rebase # did not work, my commit is lost git branch git checkout master # going back to where we started git log git reset c6c5265e4054805084f96ff796ed06326959fb26 # going back to the commit before my 1st commit git log git status git pull --rebase # worked, finally git status # my commit is lost again git diff README.md # my changes are back in the file # I have to make all my commit(s) again => double committing work # this could be very painful for larger changes git add README.md git commit -m "2nd try" # my "1st try" commit is back!? # my "2nd try" commit magically disappeared git pull --rebase git log git status git diff pico README.md # another change added to demonstrate "git pull --rebase" is blocked git status git pull --rebase # does not work when uncommited changes are present!? # ... even though there are no conflicting changes at all! # I want to revert my previous local change... git revert README.md # does not work git reset README.md # does not work echo "giving up with git" exit