Git Pull Vs Fetch | Git Tutorial For Beginners
This article will explain you the basic difference between git pull and git fetch. Let’s get started.
When you are using the git fetch command, All of the changes or updates in your remote will be downloaded to your local working areas but it will not affect your current code base. For example, suppose you are working on a branch name ui-development and you want to fetch a updated change from your remote repository but don’t wants to affect your current branch working files, Then you will apply the command git fetch. Git fetch only downloads new data from a remote repository but it doesn’t integrate any of this new data into your working files.
Using the git pull command, All of the changes or updates in your remote will be downloads to your local current working branch and it will update your working files as well. In short, To update your current HEAD branch with the latest changes from the remote server, you will use the command git pull.