Before creating a new feature branch and pushing, always run these pre-flight checks:
git fetch origin main— ensure remote is up to dategit status— confirm working tree is clean, no uncommitted changesgit log --oneline main --not origin/main— confirm no unpushed commits on main- Check for stale feature branches and clean them up if needed
Only proceed with creating a new branch and pushing after all checks pass.