Part 5
Branches and Merging Revisited

Now you have the basics down, understand the concepts of branches, and have the know-how to collaborate with other developers. It’s time to revisit branches and some of the more advanced things you can do with them.

For basic branch usage, see Part III, Organizing Your Repository with Branches and Tags. This part covers tasks related to managing branches once they’ve been created. For example, what happens when you edit the same file in different ways in two branches and then attempt to merge them back together? A conflict can occur. We cover multiple ways to handle that in this part.

Covered in this part:

  • Conflicts are going to happen. Git tries to figure out how to handle merging changes as best it can, but sometimes it can’t. Task 24, Handling Conflicts, covers how to fix cases where a conflict is created.

  • You can also use a GUI tool for managing conflicts. Task 25, Handling Conflicts with a GUI, covers that.

  • Sometimes you need to temporarily hide changes in your working tree. We see how you do this in Task 26, Temporarily Hiding Changes.

  • There’s more than one way to get changes between branches. Task 27, Cherry-Picking Commits, introduces you to another way to pull individual changes from one branch into another.

  • We revisit the git rebase command in Task 28, Controlling How You Replay Commits, to learn how to use rebase interactively.

  • You can move branches around. There are several ways to do this, depending on the circumstance. Look at Task 29, Moving Branches, to see how.

Now, let’s brush up on our conflict resolution skills.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.191.195.111