Sync with a remote Git repository (fetch, pull, sync)
Before you can share the results of your work by pushing your changes to the upstream, you need to synchronize with the remote repository to make sure your local copy of the project is up to date. You can do this in one of the following ways: fetch or pull changes, as well as sync the local project with the remote.
When you fetch changes from the upstream, all new data from commits that were made since you last synced with the remote repository is downloaded into your local copy. This new data is not integrated into your local files, and changes are not applied to your code.
Fetched changes are stored as a remote branch, which gives you a chance to review them before you merge them with your files. Since fetch does not affect your local development environment, this is a safe way to get an update of all changes to a remote repository.
There are two ways to fetch changes from the upstream:
Select Git | Fetch from the main menu.
Alternatively, in the Branches menu, click the name of the branch that is currently checked out, then choose Remote Branches | Fetch.
If you need to get changes into the current branch from the remote tracked branch, use pull.
git pull, Fleet automatically saves your uncommitted changes by stashing them.
To pull changes into the local branch from the remote tracked branch:
Check out the branch you want to update by clicking its name in the Branches menu.
Choose Git | Pull in the main menu or Press ⌃ G,⌃ U.
The Unsynced commits tab is a part of the Git tool. It helps you synchronize the local branch with the remote tracked branch.
After you perform the fetch operation, this tab will indicate if there are any unsynchronized commits between your local branch and the remote tracked branch.
To synchronize the changes between your local branch and the remote tracked branch:
In the Unsynced commits tab, click Sync.
In the Git Sync dialog that opens, confirm the operation by choosing Sync.
First, Fleet pushes local changes to the remote tracked branch. Then, if the remote branch also contains unsynchronized commits, Fleet pulls them into the local branch.