Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build.sh 명령어 문제 확인요망 #108

Open
thomasJang opened this issue Sep 16, 2017 · 0 comments
Open

build.sh 명령어 문제 확인요망 #108

thomasJang opened this issue Sep 16, 2017 · 0 comments

Comments

@thomasJang
Copy link
Member

#!/usr/bin/env bash

LOG=`git log --pretty=oneline --abbrev-commit -1`

rm -rf .subsplit

case "$LOG" in
  *MAJOR@*) echo "Major Version"; VERSION_TYPE="MAJOR";;
  *MINOR@*) echo "Minor version"; VERSION_TYPE="MINOR";;
  *PATCH@*) echo "Patch Version"; VERSION_TYPE="PATCH";;
esac

if [ $VERSION_TYPE ]
then
    git checkout master

    git pull origin master

    case "$VERSION_TYPE" in
      *MAJOR*) VERSION=$(npm version major --force);;
      *MINOR*) VERSION=$(npm version minor --force);;
      *PATCH*) VERSION=$(npm version patch --force);;
    esac

    VERSION=$(echo $VERSION | cut -c 2-)

    echo "VERSION : " $VERSION

    echo "START VERSION UP PROCESS"

    npm install && gulp version

    git add *

    echo "Git Commit & Push"

    git commit -m "$VERSION RELEASED" && git pull origin master && git push origin master
fi

에서 VERSION_TYPE 이 없는 상황이 나오고 있습니다.
도움이 필요합니다.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant