Newbie open-source contributor here.
I forked the TortoiseGit repository on GitLab, then cloned it on my computer, edited one file, and committed to branch master.
A few days have passed and I want to update my local working copy with the latest changes from upstream, before pushing to my remote fork and opening a merge request (and of course doing more development/testing etc).
I added a remote called upstream to my repo and now I'm not sure what would be the recommended action:
- git pullfrom- upstream/masterto my checked-out branch- master
- git pull --rebase//
- git fetchfollowed by- git rebase.
These are the approaches I found during my research. Unfortunately I could not find a comprehensive review of each, nor a recommendation as to which one is typical practice when working in projects from GitHub, GitLab or even those like the Linux kernel.
I tried methods 1 and 3. Method 1 (pull) generates a merge commit (--ff-only is not possible) and my history is, in a way, polluted. It also creates conflicts. Method 3 (rebase) does neither, but I'm not sure how rebase behaves after commits are pushed to remote and so I'm afraid it might cause problems going forward.
So there's my question.
Thank you.
 
     
    