git checkout master
git merge dev

#!/usr/bin/env sh

set -e 
echo "Enter release version: "
read VERSION
read -p "Releasing $VERSION are you sure(y/n) " -n 1 -r
echo
if [[ $REPLY =~ ^[Yy]$ ]]; then
    echo "Releasing $VERSION ..."
    if [[ -z $SKIP_TESTS ]]; then
        npm run lint
    fi

    #build
    VERSION=$VERSION npm run build

    # commit
    git add -A
    npm version $VERSION --message "[release] $VERSION"

    #publish
    git push origin master
    git push origin refs/tags/v"$VERSION"
    git checkout dev
    git rebase master
    git push origin dev
fi




