What is the most basic Git workflow that you can use every day?

Experience Level: Junior
Tags: GitSource control

Answer

Every day, you usually use the following git commands:

  • git pull (or git fetch and git merge) - get changes of other team members from the remote repository and merge them into your current branch
  • ...do some changes...
  • git status - see what are the changes in your workspace
  • git add . - add all changes to index (staging area)
  • git commit -m "Description of your changes" - commit changes from index (staging area) to your local repository
  • git push - send all changes from your local repository to the remote repository
Related Git job interview questions

Comments

No Comments Yet.
Be the first to tell us what you think.
Git for beginners
Git for beginners

Are you learning Git ? Try our test we designed to help you progress faster.

Test yourself
25 Git questions that will help you to nail your job interview
25 Git questions that will help you to nail your job interview

Are you learning Git ? Try our test we designed to help you progress faster.

Test yourself