Git - Life Cycle


In this chapter, we will discuss life cycle of Git. In later chapters, we will see Git command for each operation.

General workflow is like this:

  1. You clone Git repository as a working copy.

  2. You modify working copy by adding / editing files.

  3. If necessary, you also update working copy by taking other developers' changes.

  4. You review changes before commit.

  5. You commit changes. If everything was fine, then you push changes to the repository.

  6. After committing if you realize something was wrong, then you correct the last commit and push changes to the repository.

Below is pictorial representation of work flow.

Git Tutorial