DEV Community

Agus Sudarmanto
Agus Sudarmanto

Posted on

GIT Command

Fix issues

GIT_ISSUE_NAME="212 location not found"
GIT_BRANCH_NAME=$(echo $GIT_ISSUE_NAME | tr '[:upper:]' '[:lower:]' | tr '/' '-' | tr ' ' '-')

git checkout -b $GIT_BRANCH_NAME

git add .
-- or --
git add -u

git commit -m "Fixed a bug for #212"
git push -u origin $BRANCH_NAME
Enter fullscreen mode Exit fullscreen mode

Add Tag

GIT_TAG_NAME=`date "+%Y-%m-%d_%H-%M-%S"`
git tag -a $GIT_TAG_NAME -m $GIT_TAG_NAME
git push origin --tags
Enter fullscreen mode Exit fullscreen mode

Top comments (0)