#!/bin/sh

currentBranch=$2
options=$3

if [[ $1 = "-a" ]]; then
    count=`git branch | grep develop | wc -l`

    if [[ $count -le 1 ]]; then
        baseBranch=develop
    else
        echo "Please select the branch based on:"
        select baseBranch in `git branch | grep -E "$3"`
        do
            break
        done
    fi

    git config ztool.gitf.branch.$currentBranch $baseBranch
    git config gitflow.branch.develop $baseBranch

    git config gitflow.branch.develop
elif [[ $1 = "-d" ]]; then
    baseBranch=`git config --list | grep ztool.gitf.branch.$currentBranch | cut -d '=' -f 2`

    git config gitflow.branch.develop $baseBranch

    git config --unset ztool.gitf.branch.$currentBranch
else
    echo "unkonw argument"
fi
#!/bin/sh

currentBranch=$2
options=$3

if [[ $1 = "-a" ]]; then
    count=`git branch | grep develop | wc -l`

    if [[ $count -le 1 ]]; then
        baseBranch=develop
    else
        echo "Please select the branch based on:"
        select baseBranch in `git branch | grep -E "$3" | cut -d ' ' -f 2,3`
        do
            break
        done
    fi

    git config ztool.gitf.branch.$currentBranch $baseBranch
    git config gitflow.branch.develop $baseBranch

    git config gitflow.branch.develop
elif [[ $1 = "-d" ]]; then
    baseBranch=`git config --list | grep ztool.gitf.branch.$currentBranch | cut -d '=' -f 2`

    git config gitflow.branch.develop $baseBranch

    git config --unset ztool.gitf.branch.$currentBranch
else
    echo "unkonw argument"
fi
Fix options display error with gitf
Fix options display error with gitf
