forked from angular/angular
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
build(es2015): fix bad merge of angular#13471 (angular#14020)
- Loading branch information
1 parent
163ecfe
commit 2cbdddd
Showing
4 changed files
with
32 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -68,10 +68,10 @@ function publishRepo { | |
|
||
# Publish all individual packages from packages-dist. | ||
function publishPackages { | ||
PKGS_DIST=dist/packages-dist | ||
if [[ -n "${EXPERIMENTAL_ES2015_DISTRO}" ]]; then | ||
PKGS_DIST=dist/packages-dist-es2015 | ||
fi | ||
GIT_SCHEME=$1 | ||
PKGS_DIST=$2 | ||
BRANCH=$3 | ||
|
||
for dir in $PKGS_DIST/*/ dist/tools/@angular/tsc-wrapped | ||
do | ||
COMPONENT="$(basename ${dir})" | ||
|
@@ -80,12 +80,12 @@ function publishPackages { | |
COMPONENT="${COMPONENT//_/-}" | ||
JS_BUILD_ARTIFACTS_DIR="${dir}" | ||
|
||
if [[ "$1" == "ssh" ]]; then | ||
if [[ "$GIT_SCHEME" == "ssh" ]]; then | ||
REPO_URL="[email protected]:${ORG}/${COMPONENT}-builds.git" | ||
elif [[ "$1" == "http" ]]; then | ||
elif [[ "$GIT_SCHEME" == "http" ]]; then | ||
REPO_URL="https://github.com/${ORG}/${COMPONENT}-builds.git" | ||
else | ||
die "Don't have a way to publish to scheme $1" | ||
die "Don't have a way to publish to scheme $GIT_SCHEME" | ||
fi | ||
SHA=`git rev-parse HEAD` | ||
SHORT_SHA=`git rev-parse --short HEAD` | ||
|
@@ -101,16 +101,24 @@ function publishPackages { | |
} | ||
|
||
# See DEVELOPER.md for help | ||
BRANCH=${TRAVIS_BRANCH:-$(git symbolic-ref --short HEAD)} | ||
CUR_BRANCH=${TRAVIS_BRANCH:-$(git symbolic-ref --short HEAD)} | ||
if [ $# -gt 0 ]; then | ||
ORG=$1 | ||
publishPackages "ssh" | ||
publishPackages "ssh" dist/packages-dist $CUR_BRANCH | ||
if [[ -e dist/packages-dist-es2015 ]]; then | ||
publishPackages "ssh" dist/packages-dist-es2015 ${CUR_BRANCH}-es2015 | ||
fi | ||
|
||
elif [[ \ | ||
"$TRAVIS_REPO_SLUG" == "angular/angular" && \ | ||
"$TRAVIS_PULL_REQUEST" == "false" && \ | ||
"$CI_MODE" == "e2e" ]]; then | ||
ORG="angular" | ||
publishPackages "http" | ||
publishPackages "http" dist/packages-dist $CUR_BRANCH | ||
if [[ -e dist/packages-dist-es2015 ]]; then | ||
publishPackages "http" dist/packages-dist-es2015 ${CUR_BRANCH}-es2015 | ||
fi | ||
|
||
else | ||
echo "Not building the upstream/${BRANCH} branch, build artifacts won't be published." | ||
echo "Not building the upstream/${CUR_BRANCH} branch, build artifacts won't be published." | ||
fi |