1
0
Fork 0

Allow release from yarn run

Running `yarn run release` causes issues as it can't communicate with
the proper npm registry. This happens because yarn overrides the
`npm_config_registry` variable, on which the publishing depends.

In this commit I revert the value to its default, allowing the release
script to be run either with `npm run release` or `yarn run release`.
This commit is contained in:
Pixelastic 2018-11-07 14:50:23 +01:00
parent 58a6aa0fc4
commit ca8ac2c760

View file

@ -2,6 +2,10 @@
set -e # exit when error
# When running through yarn, this variable is changed, preventing the publishing
# to actually work. We revert it to its default value.
export npm_config_registry='https://registry.npmjs.org/'
if ! npm owner ls | grep -q "$(npm whoami)"
then
printf "Release: Not an owner of the npm repo, ask for it"