GitFlow Kubis1982
winget install --id=Kubis1982.GitFlow -e Git workflow management tool implementing the GitFlow branching model
winget install --id=Kubis1982.GitFlow -e Git workflow management tool implementing the GitFlow branching model
GitFlow - Git workflow management tool implementing the GitFlow branching model.
Install globally using .NET CLI:
dotnet tool install --global Kubis1982.GitFlow
Update to the latest version:
dotnet tool update --global Kubis1982.GitFlow
Uninstall:
dotnet tool uninstall --global Kubis1982.GitFlow
Build the project:
dotnet build
Run the tool:
dotnet run --project src/GitFlow
Initialize GitFlow with interactive prompts:
gitflow init [options]
Options:
-g, --global - Store configuration globally instead of locally-f, --force - Overwrite existing configurationThe command will interactively ask for:
Example session:
$ gitflow init
GitFlow Configuration
Production branch [main]:
Development branch [develop]:
Branch Prefixes
Feature branch prefix [feature/]:
Release branch prefix [release/]:
Hotfix branch prefix [hotfix/]:
Bugfix branch prefix [bugfix/]:
Version tag prefix [v]:
Merge Strategy
Merge strategy [--no-ff]:
✓ GitFlow initialized (local config)
Production branch: main
Development branch: develop
Feature prefix: feature/
Release prefix: release/
Hotfix prefix: hotfix/
Bugfix prefix: bugfix/
Version prefix: v
Merge strategy: --no-ff
To use global configuration:
gitflow init -g
Features are created from the development branch.
# Start a new feature
gitflow feature start
# Publish feature to remote
gitflow feature publish
# Checkout feature branch
gitflow feature checkout
# Update feature with latest development changes
gitflow feature update
# Finish feature (merge to development and delete)
gitflow feature finish
# Delete feature branch
gitflow feature delete
# List all feature branches
gitflow feature list
Example:
gitflow feature start PIQ-234
gitflow feature publish PIQ-234
gitflow feature finish PIQ-234
Bugfixes work the same as features (created from development).
gitflow bugfix start
gitflow bugfix publish
gitflow bugfix checkout
gitflow bugfix update
gitflow bugfix finish
gitflow bugfix delete
gitflow bugfix list
Releases are created from development and merged to both production and development.
# Start a new release
gitflow release start
# Publish release to remote
gitflow release publish
# Checkout release branch
gitflow release checkout
# Update release with latest development changes
gitflow release update
# Finish release (merge to production and development, create tag, delete branch)
gitflow release finish
# Delete release branch
gitflow release delete
# List all release branches
gitflow release list
Example:
gitflow release start 1.0.0
gitflow release finish 1.0.0 # Creates tag v1.0.0
Hotfixes are created from production (not development!) and merged to both production and development.
# Start a new hotfix (from production)
gitflow hotfix start
# Publish hotfix to remote
gitflow hotfix publish
# Checkout hotfix branch
gitflow hotfix checkout
# Update hotfix with latest production changes
gitflow hotfix update
# Finish hotfix (merge to production and development, create tag, delete branch)
gitflow hotfix finish
# Delete hotfix branch
gitflow hotfix delete
# List all hotfix branches
gitflow hotfix list
Example:
gitflow hotfix start 1.0.1
gitflow hotfix finish 1.0.1 # Creates tag v1.0.1
GitFlow configuration is stored in git config (locally or globally).
Local configuration (.git/config):
[gitflow]
production = main
development = develop
prefix.feature = feature/
prefix.release = release/
prefix.hotfix = hotfix/
prefix.bugfix = bugfix/
prefix.version = v
merge.strategy = --no-ff
Global configuration (~/.gitconfig):
gitflow init -g # Store globally
MIT