Commit 6505e6a1 authored by cmosh's avatar cmosh

readme.md

parent 06eb3944
# git-flow (AVH Edition)
A collection of Git extensions to provide high-level repository operations
for Vincent Driessen's [branching model](http://nvie.com/git-model "original
blog post"). This fork adds functionality not added to the original branch.
## Getting started
For the best introduction to get started with `git flow`, please read Jeff
Kreeftmeijer's blog post:
[http://jeffkreeftmeijer.com/2010/why-arent-you-using-git-flow/](http://jeffkreeftmeijer.com/2010/why-arent-you-using-git-flow/)
Or have a look at one of these screen casts:
* [How to use a scalable Git branching model called git-flow](http://buildamodule.com/video/change-management-and-version-control-deploying-releases-features-and-fixes-with-git-how-to-use-a-scalable-git-branching-model-called-gitflow) (by Build a Module)
* [A short introduction to git-flow](http://vimeo.com/16018419) (by Mark Derricutt)
* [On the path with git-flow](https://vimeo.com/codesherpas/on-the-path-gitflow) (by Dave Bock)
A quick cheatsheet was made by Daniel Kummer:
[http://danielkummer.github.io/git-flow-cheatsheet/](http://danielkummer.github.io/git-flow-cheatsheet/)
## Installing git-flow
See the Wiki for up-to-date [Installation Instructions](https://github.com/petervanderdoes/gitflow-avh/wiki/Installation).
## Integration with your shell
For those who use the [Bash](http://www.gnu.org/software/bash/) or [ZSH](http://www.zsh.org)
shell, you can use my [fork of git-flow-completion](https://github.com/petervanderdoes/git-flow-completion)
which includes several additions for git-flow (AVH Edition), or you can use the
original [git-flow-completion](http://github.com/bobthecow/git-flow-completion)
project by [bobthecow](http://github.com/bobthecow). Both offer tab-completion
for git-flow subcommands and branch names with my fork including tab-completion
for the commands not found in the original git-flow.
## FAQ
* See the [FAQ](http://github.com/petervanderdoes/gitflow-avh/wiki/FAQ) section
of the project Wiki.
* Version Numbering Scheme.
Starting with version 1.0, the project uses the following scheme:
\<MAJOR\>.\<MINOR\>.\<REVISION\>\
* AVH is the acronym of "A VirtualHome"
## Please help out
This project is under constant development. Feedback and suggestions are very
welcome and I encourage you to use the [Issues
list](http://github.com/petervanderdoes/gitflow-avh/issues) on Github to provide that
feedback.
Feel free to fork this repository and to commit your additions. For a list of
all contributors, please see the [AUTHORS](AUTHORS) file.
Any questions, tips, or general discussion can be posted to the Google group:
[http://groups.google.com/group/gitflow-users](http://groups.google.com/group/gitflow-users)
This is the original group set up to support the nvie branch, but I am monitoring
the list as well for any questions related to my version.
When you do post a question on the list please indicate which version you are,
using the complete version number.
## Contributing
Fork the repository. Then, run:
```shell
git clone -b master git@github.com:<username>/gitflow-avh.git
cd gitflow-avh
```
The `-b master` switch has to be added since the fork operation automatically
clones the `develop` branch of the official gitflow repository and cloning it
results in a local repository with just a `develop` branch.
If you do not have gitflow installed yet install it by running `make && make install`.
After that initialize the local gitflow repository with gitflow itself:
```shell
git flow init -d
git flow feature start <your feature>
```
Then, do work and commit your changes.
```shell
git flow feature publish <your feature>
```
When done, open a pull request to your feature branch.
## License terms
git-flow is published under the FreeBSD License, see the
[LICENSE](LICENSE) file. Although the FreeBSD License does not require you to
share any modifications you make to the source code, you are very much
encouraged and invited to contribute back your modifications to the community,
preferably in a Github fork, of course.
## git flow usage
### Initialization
To initialize a new repo with the basic branch structure, use:
git flow init [-d]
This will then interactively prompt you with some questions on which branches
you would like to use as development and production branches, and how you
would like your prefixes be named. You may simply press Return on any of
those questions to accept the (sane) default suggestions.
The ``-d`` flag will accept all defaults.
![Screencast git flow init](http://i.imgur.com/lFQbY5V.gif)
### Creating feature/release/hotfix/support branches
* To list/start/finish/delete feature branches, use:
git flow feature
git flow feature start <name> [<base>]
git flow feature finish <name>
git flow feature delete <name>
For feature branches, the `<base>` arg must be a branch, when omitted it defaults to the develop branch.
* To push/pull a feature branch to the remote repository, use:
git flow feature publish <name>
git flow feature track <name>
* To list/start/finish/delete release branches, use:
git flow release
git flow release start <release> [<base>]
git flow release finish <release>
git flow release delete <release>
For release branches, the `<base>` arg must be a branch, when omitted it defaults to the develop branch.
* To list/start/finish/delete hotfix branches, use:
git flow hotfix
git flow hotfix start <release> [<base>]
git flow hotfix finish <release>
git flow hotfix delete <release>
For hotfix branches, the `<base>` arg must be a branch, when omitted it defaults to the production branch.
* To list/start support branches, use:
git flow support
git flow support start <release> <base>
For support branches, the `<base>` arg must be a branch, when omitted it defaults to the production branch.
### Share features with others
You can easily publish a feature you are working on. The reason can be to allow other programmers to work on it or to access it from another machine. The publish/track feature of gitflow simplify the creation of a remote branch and its tracking.
When you want to publish a feature just use:
git flow feature publish <name>
or, if you already are into the `feature/<name>` branch, just issue:
git flow feature publish
Now if you execute `git branch -avv` you will see that your branch `feature/<name>` tracks `[origin/feature/<name>]`. To track the same remote branch in another clone of the same repository use:
git flow feature track <name>
This will create a local feature `feature/<name>` that tracks the same remote branch as the original one, that is `origin/feature/<name>`.
When one developer (depending on your work flow) finishes working on the feature he or she can issue `git flow feature finish <name>` and this will automatically delete the remote branch. All other developers shall then run:
git flow feature delete <name>
to get rid of the local feature that tracks a remote branch that no more exist.
### Using Hooks and Filters
For a wide variety of commands hooks or filters can be called before and after
the command.
The files should be placed in .git/hooks
In the directory hooks you can find examples of all the hooks available.
## Showing your appreciation
Of course, the best way to show your appreciation for the git-flow tool itself
remains contributing to the community. If you'd like to show your appreciation
in another way, however, consider donating through PayPal:
[![PayPal][2]][1]
[1]: https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=S85FXJ9EBHAF2&lc=US&item_name=gitflow&item_number=gitflow&no_note=0&cn=Add%20special%20instructions%20to%20the%20seller&no_shipping=1&rm=1&return=https%3a%2f%2fgithub%2ecom%2fpetervanderdoes%2fgitflow&cancel_return=https%3a%2f%2fgithub%2ecom%2fpetervanderdoes%2fgitflow&currency_code=USD&bn=PP%2dDonationsBF%3abtn_donate_SM%2egif%3aNonHosted
[2]: https://www.paypalobjects.com/en_US/i/btn/btn_donate_SM.gif
0 info it worked if it ends with ok
1 verbose cli [ '/home/clive/.nvm/versions/node/v6.6.0/bin/node',
1 verbose cli '/home/clive/.nvm/versions/node/v6.6.0/bin/npm',
1 verbose cli 'link' ]
2 info using npm@3.10.3
3 info using node@v6.6.0
4 verbose linkPkg /mnt/c/Users/clive/Code/dreidev/gitflow
5 silly gentlyRm /home/clive/.nvm/versions/node/v6.6.0/lib/node_modules/gitflow is being purged
6 verbose gentlyRm don't care about contents; nuking /home/clive/.nvm/versions/node/v6.6.0/lib/node_modules/gitflow
7 silly vacuum-fs purging /home/clive/.nvm/versions/node/v6.6.0/lib/node_modules/gitflow
8 silly vacuum-fs quitting because other entries in /home/clive/.nvm/versions/node/v6.6.0/lib/node_modules
9 verbose link build target /home/clive/.nvm/versions/node/v6.6.0/lib/node_modules/gitflow
10 silly loadCurrentTree Starting
11 silly install loadCurrentTree
12 silly install readLocalPackageData
13 silly install normalizeTree
14 silly loadCurrentTree Finishing
15 silly loadIdealTree Starting
16 silly install loadIdealTree
17 silly cloneCurrentTree Starting
18 silly install cloneCurrentTreeToIdealTree
19 silly cloneCurrentTree Finishing
20 silly loadShrinkwrap Starting
21 silly install loadShrinkwrap
22 silly loadShrinkwrap Finishing
23 silly loadAllDepsIntoIdealTree Starting
24 silly install loadAllDepsIntoIdealTree
25 silly loadAllDepsIntoIdealTree Finishing
26 silly loadIdealTree Finishing
27 silly currentTree gitflow@0.4.7
27 silly currentTree ├── balanced-match@0.4.2
27 silly currentTree ├── brace-expansion@1.1.6
27 silly currentTree ├── commander@2.9.0
27 silly currentTree ├── concat-map@0.0.1
27 silly currentTree ├── fs.realpath@1.0.0
27 silly currentTree ├── glob@7.1.1
27 silly currentTree ├── graceful-readlink@1.0.1
27 silly currentTree ├── inflight@1.0.6
27 silly currentTree ├── inherits@2.0.3
27 silly currentTree ├── interpret@1.0.1
27 silly currentTree ├── minimatch@3.0.3
27 silly currentTree ├── once@1.4.0
27 silly currentTree ├── path-is-absolute@1.0.1
27 silly currentTree ├── rechoir@0.6.2
27 silly currentTree ├── resolve@1.2.0
27 silly currentTree ├── shelljs@0.7.6
27 silly currentTree └── wrappy@1.0.2
28 silly idealTree gitflow@0.4.7
28 silly idealTree ├── balanced-match@0.4.2
28 silly idealTree ├── brace-expansion@1.1.6
28 silly idealTree ├── commander@2.9.0
28 silly idealTree ├── concat-map@0.0.1
28 silly idealTree ├── fs.realpath@1.0.0
28 silly idealTree ├── glob@7.1.1
28 silly idealTree ├── graceful-readlink@1.0.1
28 silly idealTree ├── inflight@1.0.6
28 silly idealTree ├── inherits@2.0.3
28 silly idealTree ├── interpret@1.0.1
28 silly idealTree ├── minimatch@3.0.3
28 silly idealTree ├── once@1.4.0
28 silly idealTree ├── path-is-absolute@1.0.1
28 silly idealTree ├── rechoir@0.6.2
28 silly idealTree ├── resolve@1.2.0
28 silly idealTree ├── shelljs@0.7.6
28 silly idealTree └── wrappy@1.0.2
29 silly generateActionsToTake Starting
30 silly install generateActionsToTake
31 silly generateActionsToTake Finishing
32 silly diffTrees action count 0
33 silly decomposeActions action count 0
34 silly executeActions Starting
35 silly install executeActions
36 silly doSerial global-install 0
37 silly doParallel fetch 0
38 verbose correctMkdir /home/clive/.npm/_locks correctMkdir not in flight; initializing
39 verbose lock using /home/clive/.npm/_locks/staging-1ced2b31bd2e26fd.lock for /mnt/c/Users/clive/Code/dreidev/gitflow/node_modules/.staging
40 silly doParallel extract 0
41 silly doParallel preinstall 0
42 silly doReverseSerial remove 0
43 silly doSerial move 0
44 silly doSerial finalize 0
45 silly doSerial build 0
46 silly doSerial global-link 0
47 silly doParallel update-linked 0
48 silly doSerial install 0
49 silly doSerial postinstall 0
50 verbose unlock done using /home/clive/.npm/_locks/staging-1ced2b31bd2e26fd.lock for /mnt/c/Users/clive/Code/dreidev/gitflow/node_modules/.staging
51 silly executeActions Finishing
52 silly rollbackFailedOptional Starting
53 silly rollbackFailedOptional Finishing
54 silly runTopLevelLifecycles Starting
55 silly install runTopLevelLifecycles
56 silly preinstall gitflow@0.4.7 /mnt/c/Users/clive/Code/dreidev/gitflow/gitflow-c45d7dad
57 info lifecycle gitflow@0.4.7~preinstall: gitflow@0.4.7
58 silly lifecycle gitflow@0.4.7~preinstall: no script for preinstall, continuing
59 silly build gitflow@0.4.7
60 info linkStuff gitflow@0.4.7
61 silly linkStuff gitflow@0.4.7 has /mnt/c/Users/clive/Code/dreidev as its parent node_modules
62 verbose linkBins gitflow@0.4.7
63 verbose linkMans gitflow@0.4.7
64 silly install gitflow@0.4.7 /mnt/c/Users/clive/Code/dreidev/gitflow/gitflow-c45d7dad
65 info lifecycle gitflow@0.4.7~install: gitflow@0.4.7
66 silly lifecycle gitflow@0.4.7~install: no script for install, continuing
67 silly postinstall gitflow@0.4.7 /mnt/c/Users/clive/Code/dreidev/gitflow/gitflow-c45d7dad
68 info lifecycle gitflow@0.4.7~postinstall: gitflow@0.4.7
69 verbose lifecycle gitflow@0.4.7~postinstall: unsafe-perm in lifecycle true
70 verbose lifecycle gitflow@0.4.7~postinstall: PATH: /home/clive/.nvm/versions/node/v6.6.0/lib/node_modules/npm/bin/node-gyp-bin:/mnt/c/Users/clive/Code/dreidev/gitflow/node_modules/.bin:/home/clive/.nvm/versions/node/v6.6.0/bin:/home/clive/.nvm/versions/node/v6.6.0/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games:/opt/go_appengine
71 verbose lifecycle gitflow@0.4.7~postinstall: CWD: /mnt/c/Users/clive/Code/dreidev/gitflow
72 silly lifecycle gitflow@0.4.7~postinstall: Args: [ '-c',
72 silly lifecycle 'curl https://raw.githubusercontent.com/dreidev/gitflow/develop/contrib/gitflow-installer.sh > gitflow-installer.sh; chmod a+x gitflow-installer.sh; sudo bash gitflow-installer.sh install stable' ]
73 silly lifecycle gitflow@0.4.7~postinstall: Returned: code: 2 signal: null
74 info lifecycle gitflow@0.4.7~postinstall: Failed to exec postinstall script
75 verbose stack Error: gitflow@0.4.7 postinstall: `curl https://raw.githubusercontent.com/dreidev/gitflow/develop/contrib/gitflow-installer.sh > gitflow-installer.sh; chmod a+x gitflow-installer.sh; sudo bash gitflow-installer.sh install stable`
75 verbose stack Exit status 2
75 verbose stack at EventEmitter.<anonymous> (/home/clive/.nvm/versions/node/v6.6.0/lib/node_modules/npm/lib/utils/lifecycle.js:242:16)
75 verbose stack at emitTwo (events.js:106:13)
75 verbose stack at EventEmitter.emit (events.js:191:7)
75 verbose stack at ChildProcess.<anonymous> (/home/clive/.nvm/versions/node/v6.6.0/lib/node_modules/npm/lib/utils/spawn.js:40:14)
75 verbose stack at emitTwo (events.js:106:13)
75 verbose stack at ChildProcess.emit (events.js:191:7)
75 verbose stack at maybeClose (internal/child_process.js:877:16)
75 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:226:5)
76 verbose pkgid gitflow@0.4.7
77 verbose cwd /mnt/c/Users/clive/Code/dreidev/gitflow
78 error Linux 3.4.0+
79 error argv "/home/clive/.nvm/versions/node/v6.6.0/bin/node" "/home/clive/.nvm/versions/node/v6.6.0/bin/npm" "link"
80 error node v6.6.0
81 error npm v3.10.3
82 error code ELIFECYCLE
83 error gitflow@0.4.7 postinstall: `curl https://raw.githubusercontent.com/dreidev/gitflow/develop/contrib/gitflow-installer.sh > gitflow-installer.sh; chmod a+x gitflow-installer.sh; sudo bash gitflow-installer.sh install stable`
83 error Exit status 2
84 error Failed at the gitflow@0.4.7 postinstall script 'curl https://raw.githubusercontent.com/dreidev/gitflow/develop/contrib/gitflow-installer.sh > gitflow-installer.sh; chmod a+x gitflow-installer.sh; sudo bash gitflow-installer.sh install stable'.
84 error Make sure you have the latest version of node.js and npm installed.
84 error If you do, this is most likely a problem with the gitflow package,
84 error not with npm itself.
84 error Tell the author that this fails on your system:
84 error curl https://raw.githubusercontent.com/dreidev/gitflow/develop/contrib/gitflow-installer.sh > gitflow-installer.sh; chmod a+x gitflow-installer.sh; sudo bash gitflow-installer.sh install stable
84 error You can get information on how to open an issue for this project with:
84 error npm bugs gitflow
84 error Or if that isn't available, you can get their info via:
84 error npm owner ls gitflow
84 error There is likely additional logging output above.
85 verbose exit [ 1, true ]
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment