A safer, beginner-friendly approach that preserves history and avoids force pushing.
The Workflow
# feature → develop
git checkout develop
git pull origin develop
git checkout feature
git merge develop --no-commit --no-ff
# resolve conflicts, if any
git commit -am 'merged with develop'
git push origin feature