element-plus/scripts/publish.sh
jeremywu 70c31d0bec
build(build): buid/add-locale-theme-in-es-build (#1132)
- Now lib provides cjs format exports and es provides esm format
2020-12-27 18:05:32 +08:00

14 lines
495 B
Bash

#! /usr/bin/bash
# Do not run this file without setting the environment variables, you will end up fatal error
# If you wish to run this locally, please change the env variable before running this.
# echo "//${REGISTRY}/:_authToken=${TOKEN}" > .npmrc
cat package.json \
| grep -v '"private":' \
| grep -v '"version":' \
| sed "s/\(\"name\": \"element-plus\"\)/\1,\n \"version\": \"${TAG_VERSION}\"/g" > package.json.bak
cat package.json.bak > package.json
npm publish --registry ${REGISTRY}