• Share
  • Email
  • Embed
  • Like
  • Save
  • Private Content
Git flow
 

Git flow

on

  • 3,169 views

珠三角技术沙龙-8月份

珠三角技术沙龙-8月份

Statistics

Views

Total Views
3,169
Views on SlideShare
3,169
Embed Views
0

Actions

Likes
8
Downloads
69
Comments
0

0 Embeds 0

No embeds

Accessibility

Categories

Upload Details

Uploaded via as Microsoft PowerPoint

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

    Git flow Git flow Presentation Transcript

    • Git Flow Shaokun Wu [email_address]
    • Why Git?
      • 随意的分支 (Branch) 与合并 (Merge)
      • 分布式的、本地的代码库 (Repository)
      • 快捷、轻量
      • 任意的工作流程
      • GitHub
    • 问题呢?
      • 把 Git 当 SVN 用,在 master 分支开发
      • 依然避免 Branch/Merge
      • 任意的工作流程,让人无从下手
      • 依旧习惯集中式版本控制的思维
    • Git Flow - by nvie 一种值得参考的工作流程
    •  
    • 主分支 master, develop
    • master, develop 分支
      • 用途:
        • master HEAD - 正式版
        • develop HEAD - 最新的开发版
        • 当 develop 足够稳定时候,将合并到 master ,并且 tag 上发布版本号
      • 存在周期:
        • 永远存在
    • 辅助分支 feature, release, hotfix
    • feature 分支
      • 必须遵循:
        • 从 develop 分支
        • 合并回 develop
        • 任意命名,除了 master, develop, release-*, hotfix-*
      • 用途:
        • 用于开发新的功能特性 (feature)
      • 存在周期:
        • 合并到 develop 后删除
    •  
    • release 分支
      • 必须遵循:
        • 从 develop 分支
        • 合并回 develop, master
        • 命名为 release-*
      • 用途:
        • 为最终正式版做准备
        • 提交 (commit) 小的 bug fix
      • 存在周期:
        • 合并到 develop 后删除
    • hotfix 分支
      • 必须遵循:
        • 从 master 分支
        • 合并回 develop, master
        • 命名为 hotfix-*
      • 用途:
        • 同样为最终正式版做准备
        • 提交 (commit) 小的 bug fix
        • 正式版发生重大的错误,必须立刻修复
      • 存在周期:
        • 合并到 develop/release 后删除
    • gitflow
    • $ git flow init No branches exist yet. Base branches must be created now. Branch name for production releases: [master] Branch name for "next release" development: [develop] How to name your supporting branch prefixes? Feature branches? [feature/] Release branches? [release/] Hotfix branches? [hotfix/] Support branches? [support/] Version tag prefix? []
    • $ git flow feature start login $ git flow feature finish login
    • $ git flow release start v0.1.0 $ git flow release finish v0.1.0
    • git-flow-completion Bash, Zsh
      • A successful Git branching model
        • http://nvie.com/git-model
      • Why aren’t you using git-flow?
        • http://jeffkreeftmeijer.com/2010/why-arent-you-using-git-flow/
      • http://github.com/nvie/gitflow
      • http:// github.com/bobthecow/git -flow-completion