Skip to content

Commit fcd958d

Browse files
devversiondylhunn
authored andcommitted
build: update build scripts to no longer build View Engine output (#43431)
Removes View Engine compilation from the package builder script. For v13, we can no longer ship View Engine packages. PR Close #43431
1 parent 7cba3f3 commit fcd958d

File tree

6 files changed

+6
-72
lines changed

6 files changed

+6
-72
lines changed

.circleci/config.yml

Lines changed: 1 addition & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,7 @@ var_4_win: &cache_key_win_fallback v1-angular-win-node-14-{{ checksum "month.txt
3939
var_5: &components_repo_unit_tests_cache_key v1-angular-components-{{ checksum "month.txt" }}-d090617912da8e70aa336aa5b4d804b1b535402e
4040
var_6: &components_repo_unit_tests_cache_key_fallback v1-angular-components-{{ checksum "month.txt" }}
4141

42-
# Workspace initially persisted by the `setup` job, and then enhanced by `build-npm-packages` and
43-
# `build-ivy-npm-packages`.
42+
# Workspace initially persisted by the `setup` job, and then enhanced by `build-npm-packages`.
4443
# https://circleci.com/docs/2.0/workflows/#using-workspaces-to-share-data-among-jobs
4544
# https://circleci.com/blog/deep-diving-into-circleci-workspaces/
4645
var_7: &workspace_location ~/
@@ -543,24 +542,6 @@ jobs:
543542
- ~/bazel_repository_cache
544543
- ~/.cache/bazelisk
545544

546-
# Build the ivy npm packages.
547-
build-ivy-npm-packages:
548-
executor:
549-
name: default-executor
550-
resource_class: xlarge
551-
steps:
552-
- custom_attach_workspace
553-
- init_environment
554-
- run: node scripts/build/build-ivy-npm-packages.js
555-
556-
# Save the npm packages from //packages/... for other workflow jobs to read
557-
- persist_to_workspace:
558-
root: *workspace_location
559-
paths:
560-
- ng/dist/packages-dist-ivy-aot
561-
- ng/dist/angular-in-memory-web-api-dist-ivy-aot
562-
- ng/dist/zone.js-dist-ivy-aot
563-
564545
# This job creates compressed tarballs (`.tgz` files) for all Angular packages and stores them as
565546
# build artifacts. This makes it easy to try out changes from a PR build for testing purposes.
566547
# More info CircleCI build artifacts: https://circleci.com/docs/2.0/artifacts
@@ -848,9 +829,6 @@ workflows:
848829
- build-npm-packages:
849830
requires:
850831
- setup
851-
- build-ivy-npm-packages:
852-
requires:
853-
- setup
854832
- legacy-unit-tests-saucelabs:
855833
requires:
856834
- setup
@@ -892,7 +870,6 @@ workflows:
892870
# Get the artifacts to publish from the build-packages-dist job
893871
# since the publishing script expects the legacy outputs layout.
894872
- build-npm-packages
895-
- build-ivy-npm-packages
896873
- legacy-unit-tests-saucelabs
897874
- components-repo-unit-tests:
898875
requires:

scripts/build/angular-in-memory-web-api.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ function buildAngularInMemoryWebApiPackage(destDir) {
3434
console.info(`${scriptPath}:`);
3535
console.info(' Building angular-in-memory-web-api npm package');
3636
console.info('##############################');
37-
exec(`${bazelCmd} build //packages/misc/angular-in-memory-web-api:npm_package`);
37+
exec(`${bazelCmd} build //packages/misc/angular-in-memory-web-api:npm_package --config=ivy`);
3838

3939
// Create the output directory.
4040
const absDestDir = resolve(baseDir, destDir);

scripts/build/build-ivy-npm-packages.js

Lines changed: 0 additions & 37 deletions
This file was deleted.

scripts/build/build-packages-dist.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ const {buildZoneJsPackage} = require('./zone-js-builder');
1515

1616

1717
// Build the legacy (view engine) npm packages into `dist/packages-dist/`.
18-
buildTargetPackages('dist/packages-dist', false, 'Production');
18+
buildTargetPackages('dist/packages-dist', 'Production');
1919

2020
// Build the `angular-in-memory-web-api` npm package into `dist/angular-in-memory-web-api-dist/`,
2121
// because it might be needed by other scripts/targets.

scripts/build/package-builder.js

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -60,12 +60,11 @@ module.exports = {
6060
*
6161
* @param {string} destDir Path to the output directory into which we copy the npm packages.
6262
* This path should either be absolute or relative to the project root.
63-
* @param {boolean} enableIvy True, if Ivy should be used.
6463
* @param {string} description Human-readable description of the build.
6564
* @param {boolean?} isRelease True, if the build should be stamped for a release.
6665
* @returns {Array<{name: string, outputPath: string}} A list of packages built.
6766
*/
68-
function buildTargetPackages(destDir, enableIvy, description, isRelease = false) {
67+
function buildTargetPackages(destDir, description, isRelease = false) {
6968
console.info('##################################');
7069
console.info(`${scriptPath}:`);
7170
console.info(' Building @angular/* npm packages');
@@ -93,8 +92,8 @@ function buildTargetPackages(destDir, enableIvy, description, isRelease = false)
9392

9493
// Use either `--config=snapshot` or `--config=release` so that builds are created with the
9594
// correct embedded version info.
96-
exec(`${bazelCmd} build --config=${isRelease ? 'release' : 'snapshot'} --config=${
97-
enableIvy ? 'ivy' : 'view-engine'} ${targets.join(' ')}`);
95+
exec(`${bazelCmd} build --config=${isRelease ? 'release' : 'snapshot'} --config=ivy ${
96+
targets.join(' ')}`);
9897

9998
// Create the output directory.
10099
const absDestDir = resolve(baseDir, destDir);

scripts/ci/publish-build-artifacts.sh

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -130,11 +130,6 @@ function publishAllBuilds() {
130130
local latestTag=`getLatestTag`
131131

132132
publishPackages $GIT_SCHEME dist/packages-dist $CUR_BRANCH "${latestTag}+${shortSha}"
133-
134-
# don't publish ivy builds on non-master branch
135-
if [[ "${CI_BRANCH-}" == "master" ]]; then
136-
publishPackages $GIT_SCHEME dist/packages-dist-ivy-aot "${CUR_BRANCH}-ivy-aot" "${latestTag}-ivy-aot+${shortSha}"
137-
fi
138133
}
139134

140135
# See docs/DEVELOPER.md for help

0 commit comments

Comments
 (0)