O'Reilly logo

Git: Distributed Version Control—Fundamentals and Workflows by Bjørn Stachmann, René Preißel

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 4

Multiple Commits

A new commit does not have to accept any changes from the workspace. In fact, Git gives the user full control here. In the extreme case, it can be determined what changes should be incorporated in the next commit.

A commit occurs in two steps. First, all changes are collected in a buffer using the add command. This buffer is called the staging area or index. Next, the changes from the staging area are transferred to the repository using the commit command.

Figure 4.1: The route of changes in the repository

The status Command

The status command shows what changes are currently available in the workspace ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required