Skip to content

Commit

Permalink
updated release script
Browse files Browse the repository at this point in the history
  • Loading branch information
mserranom committed Jul 10, 2018
1 parent 99912a0 commit c3d8cd9
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,18 +10,24 @@ fi
NEW_VERSION=$1
BRANCH_NAME=prepare-version-${NEW_VERSION}

# prepare master branch

echo " -- preparing master branch"
git fetch
git checkout master
if [ ! -z "$(git status --untracked-files=no --porcelain)" ]; then
echo "there are uncommitted changes in tracked files"
exit 1
fi

# update version

echo " -- updating version"
npm version --no-git-tag-version ${NEW_VERSION}
git commit package.json package-lock.json -m "updated version to ${NEW_VERSION}"
git push origin master

# create release
hub release create ${NEW_VERSION} -m "${NEW_VERSION}"

echo " -- creating github release"
hub release create ${NEW_VERSION} -m "${NEW_VERSION}"


echo "Done."

0 comments on commit c3d8cd9

Please sign in to comment.