Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 9 additions & 4 deletions scripts/publish.sh
Original file line number Diff line number Diff line change
Expand Up @@ -105,12 +105,17 @@ cat CHANGELOG.md >> "${RELEASE_NOTES_FILE}"
echo "Made the release notes."

echo "Publishing to npm..."
if [[ $DRY_RUN != "" ]]; then
PUBLISH_ARGS=()
if [[ -n "$DRY_RUN" ]]; then
echo "DRY RUN: running publish with --dry-run"
npm publish --dry-run
else
npm publish
PUBLISH_ARGS+=(--dry-run)
fi

if [[ -n "$PRE_RELEASE" ]]; then
PUBLISH_ARGS+=(--tag next)
fi

npm publish "${PUBLISH_ARGS[@]}"
echo "Published to npm."

if [[ $PRE_RELEASE != "" ]]; then
Expand Down
Loading