The Rule: Always sync your branch before you write a single line of new code.
-
Visual Studio (GUI): Open Git Changes tab
$\rightarrow$ click Fetch (down arrow)$\rightarrow$ selectmain$\rightarrow$ click Pull. -
VS Code: Click Source Control icon
$\rightarrow$ ... (ellipsis)$\rightarrow$ Pull, Push$\rightarrow$ Pull from...$\rightarrow$ selectorigin/main. - Terminal (3rd Way):