17 lines
366 B
Bash
Executable File
17 lines
366 B
Bash
Executable File
#!/bin/bash
|
|
|
|
# Exit immediately if a pipeline returns non-zero status
|
|
# http://www.gnu.org/software/bash/manual/bashref.html#The-Set-Builtin
|
|
set -e
|
|
|
|
npm test
|
|
|
|
if [ -n "$npm_config_major" ]; then SEMVER="major"
|
|
elif [ -n "$npm_config_patch" ]; then SEMVER="patch"
|
|
else SEMVER="minor"; fi
|
|
|
|
npm version $SEMVER
|
|
github-publish-release
|
|
git push --follow-tags
|
|
npm publish
|