Home / IOS Development / Advanced Git | raywenderlich.com

Advanced Git | raywenderlich.com

Master Git!

Chances are if you are involved in software development you have heard of and used Git at some point in your life. Version control systems are critical to any successful collaborative project. Git is both easy to start using and meet the most complex tasks with version control. Even experienced Git users hit roadblocks for how to handle common situations.

Advanced Git is here to help! This book is the easiest and fastest way to gain hands-on experience using Git for version control of your projects.

Who this book is for

This book is for anyone who wants to harness the power of version control with Git in the software development process. The book begins with a mild introduction, and then moves on to more complicated scenarios, including merger conflicts, rebasing and more.

Topics covered in Advanced Git

  • How Git actually works: After using Git for a while, it̵
    7;s good to discover why it’s behind all things.
  • Rebasing: Rebasing and squashing do not have to be scary; It is quite a useful and advanced way to merge code to support your workflow.
  • Regret what you have done: Most frustration with Git comes from not being able to regret something you have turned on. But Git has many ways you can go back and recover after a strange merger or commit state.
  • Workflow in Git: Working with Git requires some rules to ensure that things go smoothly across development teams. Learn the most common workflows and how to decide which one to use.
  • And more!

One thing you can trust: after reading this book, you will be well prepared to use Git in your own software development workflow!

Before you begin

This section tells you some things you need to know before you begin, such as what hardware and software you need, where to find the project files for this book, and more.

Section I: Advanced Git

This section delves into Git’s inner workings, what special Git operations actually do, and will guide you through some interesting problem-solving scenarios when Git becomes cranky. You will build some mental models to understand what happens when Git complains about things to help you solve similar problems on your own in the future.

If you’ve been using Git for a while, you may be wondering how it actually works. Discover how Git is built on top of a simple store-based file system with key values, and what power this gives you.

Fusion is not always as easy as it may first seem. In this chapter you will learn how to handle merger conflicts – which occur when Git cannot figure out how to automatically combine changes.

Git stashes give you a great way to create a temporary snapshot of what you are working on, without having to create a complete commitment. Find out when it can be helpful and how you can do it.

Rebasing is poorly understood, although it can be an incredibly powerful tool. In this chapter we will cover what happens behind the scenes when you rebuild and set yourself up for some useful applications for rebuilding in the next chapters.

Rebase is much more powerful than just a replacement for merging. It provides the opportunity to rewrite the history of git repo completely.

Gitignore is easy, right? If you’ve been using it for a while, you know it’s not always true. Discover how to fix gitignore issues, such as handling files that have been accidentally committed to the repository.

One of the most common questions related to git is “how can I get out of this mess?” In this chapter you will learn about the different “undo” commands that git gives – what they are and when to use them.

Section II: Git Workflows

Now that you understand how Git works and how to use some of the advanced features, you need to learn how to incorporate Git into your software development lifecycle. Best practices and more formal Git workflows have been established out there.

These formal Git workflows, they are all good, and in some cases they are all bad. It depends on what you want to achieve in your repo, and how your own team works. GitFlow is one of the most popular branching strategies, but there are alternative models that work well in many situations. This section will introduce you to these workflows and branching models, and explain what problems they solve and what problems they create.

This model means you work masters all the time. While this may seem daunting, it actually works quite well for small teams with rare commitments.

Function branches are used to create new functions in your code, and are then merged to master when they are finished.

A popular method of managing the team’s development workflow. In fact, there are even plugins for IDEs that support this Git workflow.

A popular method of managing the team’s development workflow. In fact, there are even plugins for IDEs that support this Git workflow.

Source link