Create a branch for a new function only in the local branch or on local and remote branches?

I follow this guide: gitflow

Usually, when I implement a new function, I create a new branch (only for the local one), after I finish my changes, I pull out the development branch, merge with my local branch and push back to develop

git checkout -b new-feature

git add.
git commit -m "finish the new feature"

git pull origin develop
git checkout develop
git merge new-feature
git push

However, my colleague creates a remote branch (drops out of the development branch). When it finishes a new function, it merges with the development branch.

So am I mistaken, or is he mistaken? Or are we both true?

+4
1

.

, , . - , git push origin -u feature_branch.

- , , . , git rebase, , Git - - ( - , ).

+3

Source: https://habr.com/ru/post/1616228/


All Articles