Note that there are a couple of versions of the git-flow script floating around. The AVH version (https://github.com/petervanderdoes/gitflow/) is newer preferred over https://github.com/nvie/gitflow.

 

A good starting point is the git-flow cheatsheet. See also this Atlassian Gitflow Workflow Tutorial. The Installation page covers Windows, Linux and Mac.

1.8.0 (AVH Edition)

Linux:

  1. Append /usr/local/bin to $PATH in .bashrc
  2. Download and execute gitflow-installer.sh
wget --no-check-certificate -q https://raw.github.com/petervanderdoes/gitflow/develop/contrib/gitflow-installer.sh
chmod +x gitflow-installer.sh
sudo ./gitflow-installer.sh install stable

Mac OS X:

brew install git-flow-avh

Windows:

  1. Update cygwin and make sure latest version of git is installed.
  2. Download and execute gitflow-installer.sh
wget -nd -nv --no-check-certificate -q https://raw.github.com/petervanderdoes/gitflow/develop/contrib/gitflow-installer.sh
chmod +x gitflow-installer.sh
./gitflow-installer.sh install stable

Reinitializing

Note: git flow init adds the following lines to the .git/config file in your local repo:

[gitflow "branch"]
        master = master
        develop = develop
[gitflow "prefix"]
        feature = feature/
        release = release/
        hotfix = hotfix/
        support = support/
        versiontag = v

If you need to redo the git flow init, simply execute:

git flow init -f

Uninstalling

Mac OS X:

brew unlink git-flow

Linux:

sudo yum erase gitflow

Reference:

  • No labels