Skip to content

LBEM-CH/gitflow-lbem-completion

 
 

Repository files navigation

git-flow-completion

Bash, Zsh and fish completion support for git-flow (LBEM Edition).

The contained completion routines provide support for completing:

  • git-flow init and version
  • feature, bugfix, hotfix and release branches
  • remote feature, bugfix, hotfix and release branch names
  • LBEM Edition commands: sync, propose, config export

About LBEM Edition

This is the LBEM Edition of git-flow, a fork of the CJS/AVH Edition with additional features:

  • sync - Sync feature/bugfix branches with their base branch
  • propose - Create pull/merge requests for feature/bugfix branches
  • config export - Export configuration to a .gitflow file
  • .gitflow file support - Shareable gitflow configuration

Changelog

LBEM Edition

  • Added completion for sync and propose subcommands
  • Added completion for config export subcommand
  • Added bugfix branch completions for fish shell

Installation for Bash

To achieve git-flow completion nirvana:

  1. Install git-completion.

  2. Install git-flow-completion.bash. Either:

    1. Place it in your bash_completion.d folder, usually something like /etc/bash_completion.d, /usr/local/etc/bash_completion.d or ~/bash_completion.d.

    2. Or, copy it somewhere (e.g. ~/git-flow-completion.bash) and put the following line in the .profile or .bashrc file in your home directory:

       source ~/git-flow-completion.bash
      
  3. If you are using Git < 1.7.1, you will need to edit git completion (usually /etc/bash_completion.d/git or git-completion.sh) and add the following line to the $command case in _git:

    _git ()
    {
            [...]
            case "$command" in
               [...]
               flow)        _git_flow ;;		
               *)           COMPREPLY=() ;;
            esac
    }
    

Installation for Zsh

To achieve git-flow completion nirvana:

  1. Update your zsh's git-completion module to the newest version -- available here. Optional if you have an up-to-date version of zsh.

  2. Install git-flow-completion.zsh. Either:

    1. Place it in your .zshrc.

    2. Or, copy it somewhere (e.g. ~/.git-flow-completion.zsh) and put the following line in your .zshrc:

       source ~/.git-flow-completion.zsh
      
    3. Or, use this file as an oh-my-zsh plugin.

Installation for fish

To achieve git-flow completion nirvana:

  1. Install git.fish in your ~/.config/fish/completions folder.

The Fine Print

Author: Copyright 2012-2023 Peter van der Does. Copyright 2025 Konstantin Weindel.

Original Author: Copyright (c) 2011 Justin Hileman

Distributed under the MIT License

About

Bash, Zsh and fish completion support for git-flow.

Resources

License

Code of conduct

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Shell 100.0%