blob: be21d205c81db8ccca7dd87ac1bea150c21dd2fe [file] [log] [blame]
Vincent Driessen6c2d30b2010-01-26 22:18:36 +01001git-flow
2========
Vincent Driessen12c4ab42010-01-26 22:11:19 +01003A collection of Git extensions to provide high-level repository operations
Vincent Driessen4fc0bc12010-02-24 01:43:04 +01004for Vincent Driessen's [branching model](http://nvie.com/git-model "original
Vincent Driessen78c73dc2010-01-21 00:48:44 +01005blog post").
6
Vincent Driessenf206ba62010-01-26 12:44:41 +01007
Vincent Driessenc81e7a22010-01-28 00:33:24 +01008> **IMPORTANT NOTE:**
9> In release 0.2, the order of the arguments has changed to provide a logical
10> subcommand hierarchy.
Vincent Driessenf206ba62010-01-26 12:44:41 +010011
12
Vincent Driessen12c4ab42010-01-26 22:11:19 +010013Installing git-flow
14-------------------
Vincent Driessen13c94822010-02-15 20:09:02 +010015After downloading the sources from Github, also fetch the submodules:
16
17 $ git submodule init
18 $ git submodule update
19
20Then, you can install `git-flow`, using:
Vincent Driessenf206ba62010-01-26 12:44:41 +010021
Vincent Driessen12c4ab42010-01-26 22:11:19 +010022 $ sudo make install
Vincent Driessenf206ba62010-01-26 12:44:41 +010023
Vincent Driessene0b54c02010-03-19 19:27:38 +010024By default, git-flow will be installed in /usr/local. To change the prefix
25where git-flow will be installed, simply specify it explicitly, using:
Vincent Driessen12c4ab42010-01-26 22:11:19 +010026
Vincent Driessene0b54c02010-03-19 19:27:38 +010027 $ sudo make prefix=/opt/local install
Vincent Driessendd720be2010-01-27 00:00:09 +010028
29Or simply point your `PATH` environment variable to your git-flow checkout
30directory.
Vincent Driessenf206ba62010-01-26 12:44:41 +010031
32
Vincent Driessen78c73dc2010-01-21 00:48:44 +010033Please help out
34---------------
Vincent Driessenc49c7932010-02-24 01:22:48 +010035This project is still under development. Feedback and suggestions are very
36welcome and I encourage you to use the [Issues
37list](http://github.com/nvie/gitflow/issues) on Github to provide that
Vincent Driessenf206ba62010-01-26 12:44:41 +010038feedback.
Vincent Driessen78c73dc2010-01-21 00:48:44 +010039
40Feel free to fork this repo and to commit your additions.
41
Vincent Driessen78c73dc2010-01-21 00:48:44 +010042
Vincent Driessen5d1dbe72010-04-04 15:52:55 +020043License terms
44-------------
45git-flow is published under the liberal terms of the BSD License, see the
46[LICENSE](LICENSE) file. Although the BSD License does not require you to share
47any modifications you make to the source code, you are very much encouraged and
48invited to contribute back your modifications to the community, preferably
49in a Github fork, of course.
50
51
Vincent Driessenc49c7932010-02-24 01:22:48 +010052Typical usage:
53--------------
Vincent Driessen78c73dc2010-01-21 00:48:44 +010054
Vincent Driessenc49c7932010-02-24 01:22:48 +010055### Initialization
56
57To initialize a new repo with the basic branch structure, use:
Vincent Driessen12c4ab42010-01-26 22:11:19 +010058
Vincent Driessenc49c7932010-02-24 01:22:48 +010059 git flow init
Vincent Driessenf9ebb072010-02-22 07:56:04 +010060
Vincent Driessenc49c7932010-02-24 01:22:48 +010061This will then interactively prompt you with some questions on which branches
62you would like to use as development and production branches, and how you
63would like your prefixes be named. You may simply press Return on any of
64those questions to accept the (sane) default suggestions.
65
66
67### Creating feature/release/hotfix/support branches
Vincent Driessen12c4ab42010-01-26 22:11:19 +010068
Vincent Driessenc81e7a22010-01-28 00:33:24 +010069* To list/start/finish feature branches, use:
70
71 git flow feature
72 git flow feature start <name> [<base>]
73 git flow feature finish <name>
74
Vincent Driessen010252a2010-02-04 10:31:29 +010075 For feature branches, the `<base>` arg must be a commit on `develop`.
Vincent Driessen78c73dc2010-01-21 00:48:44 +010076
Vincent Driessenc81e7a22010-01-28 00:33:24 +010077* To list/start/finish release branches, use:
Vincent Driessen78c73dc2010-01-21 00:48:44 +010078
Vincent Driessen04839ae2010-01-28 01:07:20 +010079 git flow release
Vincent Driessen010252a2010-02-04 10:31:29 +010080 git flow release start <release> [<base>]
Vincent Driessenc81e7a22010-01-28 00:33:24 +010081 git flow release finish <release>
Vincent Driessen78c73dc2010-01-21 00:48:44 +010082
Vincent Driessen010252a2010-02-04 10:31:29 +010083 For release branches, the `<base>` arg must be a commit on `develop`.
84
Vincent Driessenc81e7a22010-01-28 00:33:24 +010085* To list/start/finish hotfix branches, use:
Vincent Driessen78c73dc2010-01-21 00:48:44 +010086
Vincent Driessen04839ae2010-01-28 01:07:20 +010087 git flow hotfix
Vincent Driessen010252a2010-02-04 10:31:29 +010088 git flow hotfix start <release> [<base>]
Vincent Driessenc81e7a22010-01-28 00:33:24 +010089 git flow hotfix finish <release>
Vincent Driessen010252a2010-02-04 10:31:29 +010090
91 For hotfix branches, the `<base>` arg must be a commit on `master`.
Vincent Driessenc81e7a22010-01-28 00:33:24 +010092
93* To list/start support branches, use:
Vincent Driessen78c73dc2010-01-21 00:48:44 +010094
Vincent Driessenc81e7a22010-01-28 00:33:24 +010095 git flow support
Vincent Driessen010252a2010-02-04 10:31:29 +010096 git flow support start <release> <base>
97
98 For support branches, the `<base>` arg must be a commit on `master`.
Vincent Driessen78c73dc2010-01-21 00:48:44 +010099