gitflow-maven-plugin

Source code version manager

License

License

Categories

Categories

Maven Build Tools
GroupId

GroupId

com.codegik
ArtifactId

ArtifactId

gitflow-maven-plugin
Last Version

Last Version

1.3.1
Release Date

Release Date

Type

Type

maven-plugin
Description

Description

gitflow-maven-plugin
Source code version manager
Source Code Management

Source Code Management

https://github.com/codegik/gitflow

Download gitflow-maven-plugin

How to add to project

<plugin>
    <groupId>com.codegik</groupId>
    <artifactId>gitflow-maven-plugin</artifactId>
    <version>1.3.1</version>
</plugin>

Dependencies

compile (5)

Group / Artifact Type Version
org.apache.maven : maven-plugin-api jar 3.2.3
org.codehaus.mojo : versions-maven-plugin jar 2.1
org.apache.maven : maven-project jar 2.2.1
org.apache.maven.release : maven-release-manager jar 2.5.1
org.eclipse.jgit : org.eclipse.jgit jar 3.7.0.201502260915-r

provided (1)

Group / Artifact Type Version
org.apache.maven.plugin-tools : maven-plugin-annotations jar 3.4

test (1)

Group / Artifact Type Version
junit : junit jar 4.8.2

Project Modules

There are no modules declared in this project.

GitFlow Maven Plugin

The Maven plugin for Vincent Driessen's successful Git branching model.

This plugin use JGit API provided from Eclipse and Maven commands.

The picture is a little more complex. Imagine two teams working separated on the same source code, there is a project team and support team. The project team works only with features and bugfixes. The support team works with hotfixes.

The project team can work in multiple release at the same time. For example, three release on year.

Besides, there are two testing phases, one is held before delivering to the customer and the other is tested by the customer, until the customer approve the release, the source can not go to master branch.

Installation

The plugin is available from Maven central.

<build>
   <plugins>
      <plugin>
         <groupId>com.codegik</groupId>
         <artifactId>gitflow-maven-plugin</artifactId>
      </plugin>
   </plugins>
</build>

Goals Overview

gitflow:init
  • Is not necessary execute this goal unless you want plugin do it for you.
  • Create develop branch.
  • Update pom(s) version (1.0.0).
  • Create a first tag (1.0.0).
  • To execute this goal the current branch must be master.
  • Ex: mvn gitflow:init
gitflow:start-release
  • To execute this goal the current branch must be develop.
  • Start new release branch from develop and updates pom(s) with release version.
  • Ex: mvn gitflow:start-release -Dversion=1.4
gitflow:finish-release
  • To execute this goal the current branch must be develop.
  • Merge release branch into develop.
  • Increase pom version based on last Tag created.
  • Create a new tag.
  • Ex: mvn gitflow:finish-release -Dversion=1.4
gitflow:start-development
  • Start new development branch from release.
  • The branch type must be feature or bugfix.
  • Ex: mvn gitflow:start-development -DfullBranchName=feature/1.4/task3456
  • Pattern fullBranchName: <branchType=[feature|bugfix]>/<releaseVersion>/<branchName>
gitflow:finish-development
  • Merge branch development into release.
  • Ex: mvn gitflow:finish-development -DfullBranchName=feature/1.4/task3456
  • Pattern fullBranchName: <branchType=[feature|bugfix]>/<releaseVersion>/<branchName>
gitflow:start-hotfix
  • Start new hotfix branch from master.
  • Increase the pom version.
  • Ex: mvn gitflow:start-hotfix -DbranchName=issue312
gitflow:finish-hotfix
  • Merge hotfix branch into develop and master.
  • Delete hotfix branch.
  • Ex: mvn gitflow:finish-hotfix -DbranchName=issue312
gitflow:publish-release
  • After the release was tested by team and customer, finally the release will be published on branch master.
  • Find last tag from release and merge into master.
  • Delete all related branches bugfix, feature and release.
  • Ex: mvn gitflow:publish-release -Dversion=1.4
gitflow:build-release
  • While the first release is coming out, the other release also need to be tested.
  • To execute this goal the current branch must be release (Ex: release/1.5).
  • Merge develop into release branch.
  • Do not create a Tag.
  • Ex: mvn gitflow:build-release -Dversion=1.5

Good luck!

Versions

Version
1.3.1
1.3.0
1.2.12
1.2.11
1.2.10
1.2.8
1.2.7
1.2.6
1.2.4