mirror of
https://github.com/angular/angular.git
synced 2026-09-14 13:54:52 +08:00
build: update ng-dev and account for stamping changes (#48731)
* updates ng-dev and build-tooling since the previous SHAs are no longer existent after the CircleCI incident snapshot build removal. * accounts for the new stamping variables. PR Close #48731
This commit is contained in:
@@ -139,8 +139,8 @@ if (bannerFile) {
|
||||
if (stampData) {
|
||||
const versionTag = fs.readFileSync(stampData, {encoding: 'utf-8'})
|
||||
.split('\n')
|
||||
.find(s => s.startsWith('BUILD_SCM_VERSION'));
|
||||
// Don't assume BUILD_SCM_VERSION exists
|
||||
.find((s) => s.startsWith('STABLE_PROJECT_VERSION'));
|
||||
// Don't assume STABLE_PROJECT_VERSION exists
|
||||
if (versionTag) {
|
||||
const version = versionTag.split(' ')[1].trim();
|
||||
banner = banner.replace(/0.0.0-PLACEHOLDER/, version);
|
||||
@@ -190,7 +190,7 @@ const stripBannerPlugin = {
|
||||
hires: true,
|
||||
}),
|
||||
};
|
||||
}
|
||||
},
|
||||
};
|
||||
|
||||
const plugins = [
|
||||
@@ -201,7 +201,7 @@ const plugins = [
|
||||
nodeResolve({
|
||||
mainFields: ['es2020', 'es2015', 'module', 'browser'],
|
||||
jail: process.cwd(),
|
||||
customResolveOptions: {moduleDirectory: nodeModulesRoot}
|
||||
customResolveOptions: {moduleDirectory: nodeModulesRoot},
|
||||
}),
|
||||
stripBannerPlugin,
|
||||
commonjs({ignoreGlobal: true}),
|
||||
@@ -218,7 +218,7 @@ const config = {
|
||||
external: [TMPL_external],
|
||||
output: {
|
||||
banner,
|
||||
}
|
||||
},
|
||||
};
|
||||
|
||||
module.exports = config;
|
||||
|
||||
@@ -89,7 +89,7 @@ Inspect the `packages/zone.js/CHANGELOG.md` for any issues and than commit it wi
|
||||
Create a dry run build to make sure everything is ready.
|
||||
|
||||
```
|
||||
yarn bazel --output_base=$(mktemp -d) run //packages/zone.js:npm_package.pack --workspace_status_command="echo BUILD_SCM_VERSION $VERSION"
|
||||
yarn bazel --output_base=$(mktemp -d) run //packages/zone.js:npm_package.pack --workspace_status_command="echo STABLE_PROJECT_VERSION $VERSION"
|
||||
```
|
||||
|
||||
If everything looks good, commit the changes and push them to your origin to create a PR.
|
||||
|
||||
@@ -8,8 +8,8 @@ if (bazel_version_file) {
|
||||
const versionTag = require('fs')
|
||||
.readFileSync(bazel_version_file, {encoding: 'utf-8'})
|
||||
.split('\n')
|
||||
.find((s) => s.startsWith('BUILD_SCM_VERSION'));
|
||||
// Don't assume BUILD_SCM_VERSION exists
|
||||
.find((s) => s.startsWith('STABLE_PROJECT_VERSION'));
|
||||
// Don't assume STABLE_PROJECT_VERSION exists
|
||||
if (versionTag) {
|
||||
version = versionTag.split(' ')[1].trim();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user