git/fetch

Fetch from Remote

Download objects and refs from another repository

git
fetch
remote

Command

git fetch

Explanation

git fetch is used to download objects and refs from another repository. It downloads the objects and refs from another repository.

Examples

Fetch all branches from origin

git fetch

Fetch specific branch

git fetch origin main