Backlog uses cookies to deliver our services. By visiting our website, you agree to the use of cookies as described in our Cookie Policy.

You can apply the latest changes from a remote repository to your local repository using the git pull command.

For example, say the remote branch is upstream of your local branch. The remote branch would include all of the changes that belong to the local branch as shown below.

Remote branch is upstream from local branch.
Remote branch is upstream from local branch.

In this case, if we were to apply a merge from the remote branch (origin/master) into our local branch (master), it would be a fast-forward merge.

However, if there are changes in the local master branch that are not present in the remote origin/master branch, the git pull command will execute a merge and create a merge commit that ties those changes together.

Git must merge and commit before a pull if the local branch is different from the remote branch.
Git must merge and commit before a pull if the local branch is different from the remote branch.

When a pull is executed, a merge commit will be automatically created in the local repository. If there is a conflict, you will have to resolve the conflict and commit the merge manually.

If there is no conflict, the commit will be merged automatically.
If there is no conflict, the commit will be merged automatically.