Interview Prep/Git & GitHub/Push, Pull and Fetch Errors

`error: cannot pull with rebase: You have unstaged changes.`

BeginnerTroubleshootingPush, Pull and Fetch Errors
Answer

Likely causes → pull --rebase needs a clean working tree and index.

Diagnose → git status.

Fix →

git pull --rebase --autostash
# or
git stash && git pull --rebase && git stash pop

Prevent → git config --global rebase.autoStash true.

All Git & GitHub questions Roadmap: Git & GitHub

More on Push, Pull and Fetch Errors