Git life cycle

In this chapter, we will discuss Git's life cycle. And in the following chapter, we learn through Git commands for each activity.

The general work process is as follows:

You clone Git repository as a working copy.

You edit the working copy by adding / editing files.

If necessary, you can update your working copy by making changes to other developers.

You review the changes before committing.

You commit the changes. If everything is good, then you push these changes to the repository.

After committing, if you realize something is wrong, then you can correct those commits and push these changes to the repository.

Below is a picture of the work progress:

Git life cycle Picture 1

According to Tutorialspoint

Last lesson: Git environment installation

Next lesson: Create activity in Git

4.5 ★ | 2 Vote

May be interested

  • Create activity in GitPhoto of Create activity in Git
    in this chapter, we will learn how to create a remote git repository, from which we will mention it as a git server. we need a git server to allow the team to collaborate.
  • Clone activity in GitPhoto of Clone activity in Git
    we have an empty repository on the server and tom also pushed his first version. now, jerry can observe his changes. clone operation creates a remote repository instance.
  • Make changes in GitPhoto of Make changes in Git
    jerry creates a copy of the repository on his machine and decides to perform basic operations. so he created the file string.c. after adding content, string.c will look like s
  • Review changes in GitPhoto of Review changes in Git
    after rechecking the deposit details, jerry realizes that the string length cannot be negative, so he decides to change the type of my_strlen function.
  • Commit in GitPhoto of Commit in Git
    jerry commits (deposits) the changes and he wants to correct them for his recent commits. in this case, the function git commit -a will help do this. this function changes the last commit including your commit message; it creates a new commit id.
  • Push operation in HTMLPhoto of Push operation in HTML
    jerry modifies the previous commits using the git commit -a operation (signing changes) and he is ready to push the changes. push operation saves permanent data to git repository. after a successful push operation, other programmers can observe jerry's changes.