to get latest version of code Push is a command to post our latest version of code Branch is our own develop environment based on feature or whatever we will doing Commit is a command to tell git that we have done with our own feature Merge is a command to merge our work to whatever branch we want I use terminal only not using GUI
title out there. Every parts of job needs to organize well. By manual, we will copy our work files to another team Also syncronize it or just rewrite the file on local If we have different code, we need to analyze it first before rewrite.
tracking changes in computer files and coordinating work on those files among multiple people. With git, every person in project have their own copy files at their local. Some example of Git Providers are Github, Bitbucket, Gitlab, VSTS
conflicts instead Centralized. Every person have their own branch to do the feature. You can see below, Blue one is a master, the purple and green is a branch.
is for fix feature that have realeased on master realease is for realease a finish feature from develop develop is a secondary repo for development stage, it will be deploy in staging feature is a branch to do feature from backlog
create one more called develop g i t c h e c k o u t b d e v e l o p m a s t e r Explaination, we move to develop branch with command "checkout". "b" is an option to create a new branch if the branch not exist. In a fourth section "develop" is a name of branch we want to create. The last, "master" is base of branch we want to clone to our branch.
we need to tell git to create once more branch. Called "feature/featurename". and when if we finish, we merge on develop branch. You can follow command below / / c r e a t e n e w b r a n c h g i t c h e c k o u t b f e a t u r e / f e a t u r e n a m e d e v e l o p / / m e r g e f e a t u r e d o n e g i t c h e c k o u t d e v e l o p g i t m e r g e f e a t u r e / f e a t u r e n a m e g i t b r a n c h d f e a t u r e / f e a t u r e n a m e
develop stage, then we release feature to master. you can see below / / c r e a t e n e w b r a n c h g i t c h e c k o u t b r e l e a s e / r e l e a s e n a m e d e v e l o p / / m e r g e r e l e a s e d o n e g i t c h e c k o u t m a s t e r g i t m e r g e r e l e a s e / r e l e a s e n a m e g i t c h e c k o u t d e v e l o p g i t m e r g e r e l e a s e / r e l e a s e n a m e g i t b r a n c h d r e l e a s e / r e l e a s e n a m e
clone from master. / / c r e a t e n e w b r a n c h g i t c h e c k o u t b h o t f i x / h o t f i x n a m e m a s t e r / / m e r g e h o t f i x d o n e g i t c h e c k o u t m a s t e r g i t m e r g e h o t f i x / h o t f i x n a m e g i t c h e c k o u t d e v e l o p g i t m e r g e h o t f i x / h o t f i x n a m e g i t b r a n c h d h o t f i x / h o t f i x n a m e
Fortunately, Gitflow have a plugin for to make our life easier. I will attach the command below. If you first clone from repo, you should run init, "d" is to make gitflow use default option, if not include "d" you will prompted to write what is your default name of gitflow. g i t f l o w i n i t [ d ] g i t f l o w f e a t u r e g i t f l o w f e a t u r e s t a r t < n a m e > [ < b a s e > ] g i t f l o w f e a t u r e f i n i s h < n a m e > g i t f l o w r e l e a s e g i t f l o w r e l e a s e s t a r t < r e l e a s e > [ < b a s e > ] g i t f l o w r e l e a s e f i n i s h < r e l e a s e > g i t f l o w h o t f i x g i t f l o w h o t f i x s t a r t < r e l e a s e > [ < b a s e > ] g i t f l o w h o t f i x f i n i s h < r e l e a s e >