Skip to content

Commit 43c5fcd

Browse files
devversionmmalerba
authored andcommitted
build: update angular shared dev-infra code (#26530)
* build: update angular shared dev-infra code Updates the dev-infra packages and accounts for breaking changes to stamping, linker/optimization. * build: update bazel setup Note that Renovate did not update the `WORKSPACE` file, and we needed to update it ourselves. (cherry picked from commit d181eb9)
1 parent f1d83f1 commit 43c5fcd

14 files changed

+463
-624
lines changed

.github/workflows/assistant-to-the-branch-manager.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,6 @@ jobs:
1616
- uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # tag=v3.0.2
1717
with:
1818
persist-credentials: false
19-
- uses: angular/dev-infra/github-actions/branch-manager@0a49ed85541ecbb28a0e19eefce7a874c1eaab5e
19+
- uses: angular/dev-infra/github-actions/branch-manager@fa428ee0accc999f051008f0daa5651ba2728c2b
2020
with:
2121
angular-robot-key: ${{ secrets.ANGULAR_ROBOT_PRIVATE_KEY }}

.github/workflows/build-dev-app.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ jobs:
2525
- uses: actions/checkout@ec3a7ce113134d7a93b817d10a8272cb61118579 # renovate: tag=v2.0.0
2626
- uses: ./.github/actions/yarn-install
2727

28-
- uses: angular/dev-infra/github-actions/setup-bazel-remote-exec@0a49ed85541ecbb28a0e19eefce7a874c1eaab5e
28+
- uses: angular/dev-infra/github-actions/setup-bazel-remote-exec@fa428ee0accc999f051008f0daa5651ba2728c2b
2929
with:
3030
bazelrc: ./.bazelrc.user
3131

@@ -34,7 +34,7 @@ jobs:
3434
# the number of concurrent actions is determined based on the host resources.
3535
- run: bazel build //src/dev-app:web_package --symlink_prefix=dist/ --jobs=32
3636

37-
- uses: angular/dev-infra/github-actions/deploy-previews/pack-and-upload-artifact@0a49ed85541ecbb28a0e19eefce7a874c1eaab5e
37+
- uses: angular/dev-infra/github-actions/deploy-previews/pack-and-upload-artifact@fa428ee0accc999f051008f0daa5651ba2728c2b
3838
with:
3939
workflow-artifact-name: 'dev-app'
4040
pull-number: '${{github.event.pull_request.number}}'

.github/workflows/deploy-dev-app.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ jobs:
3333
npx -y firebase-tools@latest target:clear --project ${{env.PREVIEW_PROJECT}} hosting dev-app
3434
npx -y firebase-tools@latest target:apply --project ${{env.PREVIEW_PROJECT}} hosting dev-app ${{env.PREVIEW_SITE}}
3535
36-
- uses: angular/dev-infra/github-actions/deploy-previews/upload-artifacts-to-firebase@0a49ed85541ecbb28a0e19eefce7a874c1eaab5e
36+
- uses: angular/dev-infra/github-actions/deploy-previews/upload-artifacts-to-firebase@fa428ee0accc999f051008f0daa5651ba2728c2b
3737
with:
3838
github-token: '${{secrets.GITHUB_TOKEN}}'
3939
workflow-artifact-name: 'dev-app'

.github/workflows/dev-infra.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,13 @@ jobs:
1212
runs-on: ubuntu-latest
1313
steps:
1414
- uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # tag=v3.0.2
15-
- uses: angular/dev-infra/github-actions/commit-message-based-labels@0a49ed85541ecbb28a0e19eefce7a874c1eaab5e
15+
- uses: angular/dev-infra/github-actions/commit-message-based-labels@fa428ee0accc999f051008f0daa5651ba2728c2b
1616
with:
1717
angular-robot-key: ${{ secrets.ANGULAR_ROBOT_PRIVATE_KEY }}
1818
post_approval_changes:
1919
runs-on: ubuntu-latest
2020
steps:
2121
- uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # tag=v3.0.2
22-
- uses: angular/dev-infra/github-actions/post-approval-changes@0a49ed85541ecbb28a0e19eefce7a874c1eaab5e
22+
- uses: angular/dev-infra/github-actions/post-approval-changes@fa428ee0accc999f051008f0daa5651ba2728c2b
2323
with:
2424
angular-robot-key: ${{ secrets.ANGULAR_ROBOT_PRIVATE_KEY }}

.github/workflows/google-internal-tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
runs-on: ubuntu-latest
1414
steps:
1515
- uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8 # tag=v3.1.0
16-
- uses: angular/dev-infra/github-actions/google-internal-tests@0a49ed85541ecbb28a0e19eefce7a874c1eaab5e
16+
- uses: angular/dev-infra/github-actions/google-internal-tests@fa428ee0accc999f051008f0daa5651ba2728c2b
1717
with:
1818
run-tests-guide-url: http://go/angular-material-presubmit
1919
github-token: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/lock-closed.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,6 @@ jobs:
1111
lock_closed:
1212
runs-on: ubuntu-latest
1313
steps:
14-
- uses: angular/dev-infra/github-actions/lock-closed@0a49ed85541ecbb28a0e19eefce7a874c1eaab5e
14+
- uses: angular/dev-infra/github-actions/lock-closed@fa428ee0accc999f051008f0daa5651ba2728c2b
1515
with:
1616
lock-bot-key: ${{ secrets.LOCK_BOT_PRIVATE_KEY }}

WORKSPACE

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
88
# Add NodeJS rules
99
http_archive(
1010
name = "build_bazel_rules_nodejs",
11-
sha256 = "2b2004784358655f334925e7eadc7ba80f701144363df949b3293e1ae7a2fb7b",
12-
urls = ["https://github.com/bazelbuild/rules_nodejs/releases/download/5.4.0/rules_nodejs-5.4.0.tar.gz"],
11+
sha256 = "dcc55f810142b6cf46a44d0180a5a7fb923c04a5061e2e8d8eb05ccccc60864b",
12+
urls = ["https://github.com/bazelbuild/rules_nodejs/releases/download/5.8.0/rules_nodejs-5.8.0.tar.gz"],
1313
)
1414

1515
# Add sass rules

package.json

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -74,27 +74,27 @@
7474
"@angular-devkit/core": "^15.1.0",
7575
"@angular-devkit/schematics": "^15.1.0",
7676
"@angular/bazel": "15.0.4",
77-
"@angular/build-tooling": "https://github.com/angular/dev-infra-private-build-tooling-builds.git#1fd144d9f9db6a6cfe3e2617c4fc70e119a400cb",
77+
"@angular/build-tooling": "https://github.com/angular/dev-infra-private-build-tooling-builds.git#57ce1b4bb7ab323c5c7610081a93148796b4ae81",
7878
"@angular/cli": "^15.1.0",
7979
"@angular/compiler-cli": "^15.1.0",
8080
"@angular/localize": "^15.1.0",
81-
"@angular/ng-dev": "https://github.com/angular/dev-infra-private-ng-dev-builds.git#757a386a63e960c4006efd26482f0d52dd0a1604",
81+
"@angular/ng-dev": "https://github.com/angular/dev-infra-private-ng-dev-builds.git#ecad30aeac0b82fc1d2a8b9833b3f9c04311cedc",
8282
"@angular/platform-browser-dynamic": "^15.1.0",
8383
"@angular/platform-server": "^15.1.0",
8484
"@angular/router": "^15.1.0",
8585
"@axe-core/webdriverjs": "^4.3.2",
8686
"@babel/core": "^7.16.12",
8787
"@bazel/bazelisk": "1.12.1",
88-
"@bazel/buildifier": "5.1.0",
89-
"@bazel/concatjs": "5.7.2",
90-
"@bazel/esbuild": "5.7.2",
88+
"@bazel/buildifier": "6.0.1",
89+
"@bazel/concatjs": "5.7.3",
90+
"@bazel/esbuild": "5.7.3",
9191
"@bazel/ibazel": "0.16.2",
92-
"@bazel/jasmine": "5.7.2",
93-
"@bazel/protractor": "5.7.2",
94-
"@bazel/rollup": "5.7.2",
95-
"@bazel/runfiles": "5.7.2",
96-
"@bazel/terser": "5.7.2",
97-
"@bazel/worker": "5.7.2",
92+
"@bazel/jasmine": "5.7.3",
93+
"@bazel/protractor": "5.7.3",
94+
"@bazel/rollup": "5.7.3",
95+
"@bazel/runfiles": "5.7.3",
96+
"@bazel/terser": "5.7.3",
97+
"@bazel/worker": "5.7.3",
9898
"@firebase/app-types": "^0.7.0",
9999
"@material/animation": "15.0.0-canary.684e33d25.0",
100100
"@material/auto-init": "15.0.0-canary.684e33d25.0",
@@ -170,7 +170,7 @@
170170
"date-fns": "^2.28.0",
171171
"dgeni": "^0.4.14",
172172
"dgeni-packages": "^0.29.5",
173-
"esbuild": "^0.14.14",
173+
"esbuild": "^0.17.5",
174174
"firebase-tools": "^9.2.1",
175175
"fs-extra": "^9.0.1",
176176
"glob": "^7.2.0",

packages.bzl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ NPM_PACKAGE_SUBSTITUTIONS = {
1616
# Version of `tslib`
1717
"0.0.0-TSLIB": TSLIB_PACKAGE_VERSION,
1818
# Version of the local package being built, generated via the `--workspace_status_command` flag.
19-
"0.0.0-PLACEHOLDER": "{BUILD_SCM_VERSION}",
19+
"0.0.0-PLACEHOLDER": "{STABLE_PROJECT_VERSION}",
2020
# Version of `rxjs`
2121
"0.0.0-RXJS": RXJS_PACKAGE_VERSION,
2222
}

scripts/build-packages-dist.mts

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -64,17 +64,6 @@ function buildReleasePackages(distPath: string, isSnapshotBuild: boolean): Built
6464
// version placeholder is populated in the release output.
6565
const stampConfigArg = `--config=${isSnapshotBuild ? 'snapshot-build' : 'release'}`;
6666

67-
// Walk through each release package and clear previous "npm_package" outputs. This is
68-
// a workaround for: https://github.com/bazelbuild/rules_nodejs/issues/1219. We need to
69-
// do this to ensure that the version placeholders are properly populated.
70-
packageNames.forEach(pkgName => {
71-
const outputPath = getBazelOutputPath(pkgName);
72-
if (sh.test('-d', outputPath)) {
73-
sh.chmod('-R', 'u+w', outputPath);
74-
sh.rm('-rf', outputPath);
75-
}
76-
});
77-
7867
exec(`${bazelCmd} build ${stampConfigArg} ${targets.join(' ')}`);
7968

8069
// Delete the distribution directory so that the output is guaranteed to be clean. Re-create

0 commit comments

Comments
 (0)