Intermediate Git & Version Control
Q71 / 100

What is the difference between "git fetch --all" and "git fetch origin"?

Correct! Well done.

Incorrect.

The correct answer is A) "git fetch --all" fetches updates from all configured remotes, while "git fetch origin" (or just "git fetch" with a single remote) only fetches from the remote named "origin"

A

Correct Answer

"git fetch --all" fetches updates from all configured remotes, while "git fetch origin" (or just "git fetch" with a single remote) only fetches from the remote named "origin"

Explanation

Most repositories only have one remote ("origin"), so the two commands behave the same in that case, but "--all" becomes meaningful when multiple remotes (e.g. "origin" and "upstream") are configured.

Progress
71/100