Gitflow - Clouddictive

Preview:

Citation preview

GIT FLOW Clouddictivehttps://blog.clouddictive.comteam@clouddictive.com

Agenda❖ GIT Overview❖ GIT Flow❖ Master and Develop Branches❖ Feature, Release and Hotfix Branches❖ How it works❖ Other Workflows❖ Install and Demo

GIT Overview❖ Version Control System - For the code we write!.❖ Distributed - Repo stored locally with history

and on centralized location.❖ Branching and Merging ❖ Fast - Written in C + Local Repo❖ FREE + Open Source

GIT Overview

Source: http://pigne.org

GIT Overview - Branching and Merge

Source: https://www.f30.me

GIT Flow❖ Blog from Vincent Driessen in 2010 (from

Netherlands) ❖ http://nvie.com

❖ First Structured Workflow ❖ Git extension called git-flow - by Jeff Kreeftmeijer❖ http://jeffkreeftmeijer.com/2010/why-arent-y

ou-using-git-flow/(Note: Image source for this presentation is http://nvie.com)

GIT Flow - Branches❖ Master and Develop

Branches - They are there to stay

❖ Feature, Release and Hotfix - are temporary supporting branches. They support ❖ Parallel development ❖ Tracking features ❖ Bug fixes❖ Quickly fixing live

Production issues

Master and Develop❖ Master - Reflects a

production ready state.❖ Develop - Reflects a

state with the latest delivered development changes for the next release.

Feature Branch❖ Are used to develop new

features for the upcoming or a distant future release.

❖ Target release - Unknown❖ May branch off from:

develop ❖ Must merge back into:

develop ❖ Branch naming convention:

anything except master, develop, release-*, or hotfix-*

Release Branch❖ Support PROD releases - Can consist of 1-

n features❖ Testing and Bug fixing❖ Develop branch is cleared to receive

features for the next big release - Take develop code and start creating more features (branches).

❖ May branch off from:

develop ❖ Must merge back into (Finish Stage):

develop and master ❖ Branch naming convention:

release-*

Hotfix Branch❖ Like release branches❖ Fix bugs in PROD❖ May branch off from:

master ❖ Must merge back into:

develop and master ❖ Branch naming

convention:

hotfix-*

How it works - Feature

How it works - Feature finished

How it works - Release

How it works - Release finished

How it works - Hotfix

Other Workflows❖ GitHub Flow - one off from master❖ Skullcandy’s flow- feature branch based on

story/deliverables , Merged to QA branch for testing and then PROD

❖ Master Only flow❖ Backcountry flow - Master , Feature and PROD

branches

Install❖ https://github.com/nvie/gitflow/wiki/Mac-OS-X

curl -L -O https://raw.github.com/nvie/gitflow/develop/contrib/gitflow-installer.sh

sudo bash gitflow-installer.sh

Demo - Init❖ $ git-flow init

❖ git branch *developmaster

Demo - Feature❖ git-flow feature start authentication

❖ git add src❖ git commit

❖ git feature finish authentication❖ git branch

Demo - Release❖ git-flow release start 0.1.0

❖ git branch❖ git add (changes)❖ git commit

❖ git-flow release finish 0.1.0

Demo - Hotfix❖ git-flow hotfix start asset

❖ git add❖ git commit

❖ git-flow hotfix finish asset

Recommended