Why git checkout -b Sometimes Sets an Upstream

Branching from origin/main configures tracking automatically; branching from a local main does not. The rule behind it is branch.autoSetupMerge.

Last updated on September 2, 2026 · 266 words