This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export beetil_api_key=YOUR_BEETIL_API_KEY_HERE | |
# extracts the branch name | |
function plain_git_branch { | |
git symbolic-ref HEAD 2> /dev/null | sed -e 's/refs\/heads\///' | |
} | |
# extracts the part of the branch name that could be a beetil number | |
function beetil_number_from_git_branch { | |
plain_git_branch 2> /dev/null | cut -c2-9 |