Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

chore(npm): publish artifacts to npm #9376

Merged
merged 1 commit into from
Oct 6, 2014
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
14 changes: 14 additions & 0 deletions scripts/bower/publish.sh
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,8 @@ function prepare {
cd $TMP_DIR/bower-$repo
replaceJsonProp "bower.json" "version" ".*" "$NEW_VERSION"
replaceJsonProp "bower.json" "angular.*" ".*" "$NEW_VERSION"
replaceJsonProp "package.json" "version" ".*" "$NEW_VERSION"
replaceJsonProp "package.json" "angular.*" ".*" "$NEW_VERSION"

git add -A

Expand All @@ -90,6 +92,18 @@ function publish {
cd $TMP_DIR/bower-$repo
git push origin master
git push origin v$NEW_VERSION

# don't publish every build to npm
if [ "${NEW_VERSION/+sha}" = "$NEW_VERSION" ] ; then
if [ "${NEW_VERSION/-}" = "$NEW_VERSION" ] ; then
# publish releases as "latest"
npm publish
else
# publish prerelease builds with the beta tag
npm publish --tag=beta
fi
fi

cd $SCRIPT_DIR
done
}
Expand Down