Git merging
OK, so maybe you can see a bit of a pattern here. I’ve been messing with git trying to get to the point where I can do what I want with it. Now that I understand how the branching functions, the next step was figuring out how to merge.
First thing to note is that this is how you can see the file differences in the two branches:
git diff ––name–status master..branch
Other views of the data:
git diff master..branch
git log master..branch
git shortlog master..branch
So that covers what the differences are between the branches before merging. Then there’s the real merging.
git merge branch ––no–commit
Then you can look at the changes with:
git status
git diff
If you see any problems you can turn back the clock with this:
git reset ––hard
Categories: git
I think the double dashes (–) got turned into em dashes. Other than that, this works great. Thanks.
Ya, you’re right. Something in the system is modifying double-dashes to em dashes somewhere down the pipe. I just changed them to en-dashes so it’s at least clearer to read.