diff --git a/.travis/after_deploy.sh b/.travis/after_deploy.sh index f0f3cc2..b7a9236 100755 --- a/.travis/after_deploy.sh +++ b/.travis/after_deploy.sh @@ -5,6 +5,8 @@ ME=`basename "$0"` cd $DIR +git checkout master + VERSION=$(npm --no-git-tag-version version patch) git add --all diff --git a/.travis/before_deploy.sh b/.travis/before_deploy.sh index c3b62b0..87cf541 100755 --- a/.travis/before_deploy.sh +++ b/.travis/before_deploy.sh @@ -5,15 +5,17 @@ ME=`basename "$0"` cd $DIR +git remote add repo https://${GH_TOKEN}@github.com/awjh/node-red-contrib-alexa-endpoint +git fetch repo + +git checkout master + VERSION=$(echo $TRAVIS_TAG | grep -Eo '([0-9]+\.){2}[0-9]+') jq -r ".version=\"$VERSION\"" "$DIR/package.json" | cat > tmp.json mv tmp.json $DIR/package.json -git remote add repo https://${GH_TOKEN}@github.com/awjh/node-red-contrib-alexa-endpoint -git fetch repo - if [[ -n $(git status -s) ]]; then git add --all git commit -s -m "Release required version bump $VERSION [skip travis]"