码迷,mamicode.com
首页 > 其他好文 > 详细

git-flow

时间:2016-11-06 13:36:31      阅读:168      评论:0      收藏:0      [点我收藏+]

标签:config   brew   pretty   bre   ranch   ges   post   ast   cheat   

Using git-flow to automate your git branching workflow.

(原文)

技术分享

After installing git-flow (brew install git-flow), you can start using git-flow in your repository by using it’s init command. You can use it in existing projects, but let’s start a new repository:

1
2
3
4
5
6
7
8
9
10
11
12
$ git flow init
Initialized empty Git repository in ~/project/.git/
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? []

Feature branches

1. git flow feature start authentication
2. git flow feature finish authentication

Versioned releases

1. git flow release start 0.1.0
2. git flow release finish 0.1.0

Hotfixing production code

1. git flow hotfix start assets
2. git flow hotfix finish assets

set git

1
2
3
4
5
6
7
git config --global alias.br branch
git config --global alias.ci commit
git config --global alias.co checkout
git config --global alias.st status
# 很好看地显示git log
git config --global alias.lg "log --color --graph --pretty=format:‘%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen (%cr) %C(bold blue)<%an>%Creset‘ --abbrev-commit --"
# 设置用户信息
 
 

git-flow

标签:config   brew   pretty   bre   ranch   ges   post   ast   cheat   

原文地址:http://www.cnblogs.com/shtyHome/p/6034921.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!