Compare commits
25 Commits
fix-307
...
10.0.0-rc.
Author | SHA1 | Date | |
---|---|---|---|
cf86f72eb7 | |||
61486f14f1 | |||
d16a7f3ecc | |||
82761ec50e | |||
235bfa77a9 | |||
299ae1bb1c | |||
80f7522dab | |||
028921e369 | |||
a4e11bb524 | |||
a4131752d2 | |||
060dcfbba1 | |||
4be7008f80 | |||
4a0d05515e | |||
83ab99c746 | |||
270da1f69f | |||
6b0e46e36c | |||
3642707145 | |||
0ea76edfd8 | |||
d493a83b2b | |||
f1721d5cef | |||
5b3fd6aa82 | |||
6f829180f7 | |||
27b95ba64a | |||
ef405b1e90 | |||
441073bad5 |
@ -1,6 +1,4 @@
|
||||
import {exec} from 'shelljs';
|
||||
|
||||
import {MergeConfig} from './dev-infra/pr/merge/config';
|
||||
import {MergeConfig} from '../dev-infra/pr/merge/config';
|
||||
|
||||
// The configuration for `ng-dev commit-message` commands.
|
||||
const commitMessage = {
|
||||
@ -82,33 +80,11 @@ const github = {
|
||||
name: 'angular',
|
||||
};
|
||||
|
||||
/**
|
||||
* Gets the name of the current patch branch. The patch branch is determined by
|
||||
* looking for upstream branches that follow the format of `{major}.{minor}.x`.
|
||||
*/
|
||||
const getPatchBranchName = (): string => {
|
||||
const branches =
|
||||
exec(
|
||||
`git ls-remote --heads https://github.com/${github.owner}/${github.name}.git`,
|
||||
{silent: true})
|
||||
.trim()
|
||||
.split('\n');
|
||||
|
||||
for (let i = branches.length - 1; i >= 0; i--) {
|
||||
const branchName = branches[i];
|
||||
const matches = branchName.match(/refs\/heads\/([0-9]+\.[0-9]+\.x)/);
|
||||
if (matches !== null) {
|
||||
return matches[1];
|
||||
}
|
||||
}
|
||||
|
||||
throw Error('Could not determine patch branch name.');
|
||||
};
|
||||
|
||||
// Configuration for the `ng-dev pr merge` command. The command can be used
|
||||
// for merging upstream pull requests into branches based on a PR target label.
|
||||
const merge = () => {
|
||||
const patchBranch = getPatchBranchName();
|
||||
// TODO: resume dynamically determining patch branch
|
||||
const patch = '10.0.x';
|
||||
const config: MergeConfig = {
|
||||
githubApiMerge: false,
|
||||
claSignedLabel: 'cla: yes',
|
||||
@ -121,18 +97,18 @@ const merge = () => {
|
||||
},
|
||||
{
|
||||
pattern: 'PR target: patch-only',
|
||||
branches: [patchBranch],
|
||||
branches: [patch],
|
||||
},
|
||||
{
|
||||
pattern: 'PR target: master & patch',
|
||||
branches: ['master', patchBranch],
|
||||
branches: ['master', patch],
|
||||
},
|
||||
],
|
||||
requiredBaseCommits: {
|
||||
// PRs that target either `master` or the patch branch, need to be rebased
|
||||
// on top of the latest commit message validation fix.
|
||||
'master': '4341743b4a6d7e23c6f944aa9e34166b701369a1',
|
||||
[patchBranch]: '2a53f471592f424538802907aca1f60f1177a86d'
|
||||
[patch]: '4341743b4a6d7e23c6f944aa9e34166b701369a1'
|
||||
},
|
||||
};
|
||||
return config;
|
@ -648,7 +648,6 @@ groups:
|
||||
- >
|
||||
contains_any_globs(files, [
|
||||
'packages/bazel/**',
|
||||
'aio/content/guide/bazel.md'
|
||||
])
|
||||
reviewers:
|
||||
users:
|
||||
@ -953,6 +952,7 @@ groups:
|
||||
'.circleci/**',
|
||||
'.devcontainer/**',
|
||||
'.github/**',
|
||||
'.ng-dev/**',
|
||||
'.vscode/**',
|
||||
'.yarn/**',
|
||||
'dev-infra/**',
|
||||
|
11
CHANGELOG.md
11
CHANGELOG.md
@ -1,3 +1,14 @@
|
||||
<a name="10.0.0-rc.2"></a>
|
||||
# [10.0.0-rc.2](https://github.com/angular/angular/compare/10.0.0-rc.0...10.0.0-rc.2) (2020-06-01)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* **core:** reenable decorator downleveling for Angular npm packages ([#37317](https://github.com/angular/angular/issues/37317)) ([d16a7f3](https://github.com/angular/angular/commit/d16a7f3)), closes [#37221](https://github.com/angular/angular/issues/37221) [#37221](https://github.com/angular/angular/issues/37221)
|
||||
|
||||
|
||||
Note: the 10.0.0-rc.1 release on npm accidentally glitched-out midway, so we cut 10.0.0-rc.2 instead. oops :-)
|
||||
|
||||
<a name="10.0.0-rc.0"></a>
|
||||
# [10.0.0-rc.0](https://github.com/angular/angular/compare/10.0.0-next.9...10.0.0-rc.0) (2020-05-21)
|
||||
|
||||
|
@ -109,9 +109,3 @@ Options that specify files can be given as absolute paths, or as paths relative
|
||||
The [ng generate](cli/generate) and [ng add](cli/add) commands take as an argument the artifact or library to be generated or added to the current project.
|
||||
In addition to any general options, each artifact or library defines its own options in a *schematic*.
|
||||
Schematic options are supplied to the command in the same format as immediate command options.
|
||||
|
||||
|
||||
### Building with Bazel
|
||||
|
||||
Optionally, you can configure the Angular CLI to use [Bazel](https://docs.bazel.build) as the build tool. For more information, see [Building with Bazel](guide/bazel).
|
||||
|
||||
|
@ -1,122 +0,0 @@
|
||||
# Building with Bazel
|
||||
|
||||
This guide explains how to build and test Angular apps with Bazel.
|
||||
|
||||
|
||||
<div class="alert is-helpful">
|
||||
|
||||
This guide assumes you are already familiar with developing and building Angular applications using the [CLI](cli).
|
||||
|
||||
It describes features which are part of Angular Labs, and are not considered a stable, supported API.
|
||||
|
||||
</div>
|
||||
|
||||
## Using Bazel with the Angular CLI
|
||||
|
||||
The `@angular/bazel` package provides a builder that allows Angular CLI to use Bazel as the build tool.
|
||||
|
||||
To opt-in an existing application, run
|
||||
|
||||
```sh
|
||||
ng add @angular/bazel
|
||||
```
|
||||
|
||||
To use Bazel in a new application, first install `@angular/bazel` globally
|
||||
|
||||
```sh
|
||||
npm install -g @angular/bazel
|
||||
```
|
||||
|
||||
then create the new application with
|
||||
|
||||
```sh
|
||||
ng new --collection=@angular/bazel
|
||||
```
|
||||
|
||||
Now when you use Angular CLI build commands such as `ng build` and `ng serve`,
|
||||
Bazel is used behind the scenes.
|
||||
Outputs from Bazel appear in the `dist/bin` folder.
|
||||
|
||||
> The command-line output includes extra logging from Bazel.
|
||||
> We plan to reduce this in the future.
|
||||
|
||||
### Removing Bazel
|
||||
|
||||
If you need to opt-out from using Bazel, you can restore the backup files:
|
||||
|
||||
- `/angular.json.bak` replaces `/angular.json`
|
||||
|
||||
## Advanced configuration
|
||||
|
||||
<div class="alert is-helpful">
|
||||
|
||||
Editing the Bazel configuration may prevent you opting out of Bazel.
|
||||
Custom behaviors driven by Bazel won't be available in other Builders.
|
||||
|
||||
This section assumes you are familiar with [Bazel](https://docs.bazel.build).
|
||||
|
||||
</div>
|
||||
|
||||
You can manually adjust the Bazel configuration to:
|
||||
|
||||
* customize the build steps
|
||||
* parallellize the build for scale and incrementality
|
||||
|
||||
Create the initial Bazel configuration files by running the following command:
|
||||
|
||||
```sh
|
||||
ng build --leaveBazelFilesOnDisk
|
||||
```
|
||||
|
||||
Now you'll find new files in the Angular workspace:
|
||||
|
||||
* `/WORKSPACE` tells Bazel how to download external dependencies.
|
||||
* `/BUILD.bazel` and `/src/BUILD.bazel` tell Bazel about your source code.
|
||||
|
||||
You can find a full-featured example with custom Bazel configurations at https://github.com/bazelbuild/rules_nodejs/tree/master/examples/angular.
|
||||
|
||||
Documentation for using Bazel for frontend projects is linked from https://docs.bazel.build/versions/master/bazel-and-javascript.html.
|
||||
|
||||
|
||||
|
||||
## Running Bazel directly
|
||||
|
||||
In some cases you'll want to bypass the Angular CLI builder, and run the Bazel CLI directly.
|
||||
The Bazel tool is managed by the `@bazel/bazelisk` package (similar to how Node.js can be managed by `nvm`).
|
||||
You can install it globally to get the `bazelisk` command in your path, or use `$(npm bin)/bazelisk` in place of bazelisk below.
|
||||
|
||||
The common commands in Bazel are:
|
||||
|
||||
* `bazelisk build [targets]`: Compile the default output artifacts of the given targets.
|
||||
* `bazelisk test [targets]`: For whichever `*_test` targets are found in the patterns, run the tests.
|
||||
* `bazelisk run [target]`: Compile the program represented by target, and then run it.
|
||||
|
||||
To repeat the command any time the inputs change (watch mode), replace `bazelisk` with `ibazel` in these commands.
|
||||
|
||||
The output locations are printed in the output.
|
||||
|
||||
Full documentation for the Bazel CLI is at https://docs.bazel.build/versions/master/command-line-reference.html.
|
||||
|
||||
|
||||
## Querying the build graph
|
||||
|
||||
Because Bazel constructs a graph out of your targets, you can find lots of useful information.
|
||||
|
||||
Using the graphviz optional dependency, you'll have a program `dot`, which you can use with `bazel query`:
|
||||
|
||||
```bash
|
||||
$ bazel query --output=graph ... | dot -Tpng > graph.png
|
||||
```
|
||||
|
||||
See https://docs.bazel.build/versions/master/query-how-to.html for more details on `bazel query`.
|
||||
|
||||
|
||||
## Customizing `BUILD.bazel` files
|
||||
|
||||
"Rules" are like plugins for Bazel. Many rule sets are available. This guide documents the ones maintained by the Angular team at Google.
|
||||
|
||||
Rules are used in `BUILD.bazel` files, which are markers for the packages in your workspace. Each `BUILD.bazel` file declares a separate package to Bazel, though you can have more coarse-grained distributions so that the packages you publish (for example, to `npm`) can be made up of many Bazel packages.
|
||||
|
||||
In the `BUILD.bazel` file, each rule must first be imported, using the `load` statement. Then the rule is called with some attributes, and the result of calling the rule is that you've declared to Bazel how it can derive some outputs given some inputs and dependencies. Then later, when you run a `bazel` command line, Bazel loads all the rules you've declared to determine an absolute ordering of what needs to be run. Note that only the rules needed to produce the requested output will actually be executed.
|
||||
|
||||
A list of common rules for frontend development is documented in the README at https://github.com/bazelbuild/rules_nodejs/.
|
@ -54,16 +54,17 @@ Angular supports most recent browsers. This includes the following specific vers
|
||||
</td>
|
||||
<td>
|
||||
<div> 11, 10*, 9* ("compatibility view" mode not supported) </div>
|
||||
<div>*deprecated in v10, see the <a href="/guide/deprecations#ie-9-10">deprecations guide</a>.</div>
|
||||
<div>*deprecated in v10, see the {@link guide/deprecations#ie-9-10-and-mobile deprecations guide}.</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<tr>
|
||||
<td>
|
||||
IE Mobile
|
||||
IE Mobile*
|
||||
</td>
|
||||
<td>
|
||||
11
|
||||
<div>*deprecated in v10, see the {@link guide/deprecations#ie-9-10-and-mobile deprecations guide}.</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
|
@ -35,6 +35,7 @@ v9 - v12
|
||||
|
||||
| Area | API or Feature | May be removed in |
|
||||
| ----------------------------- | --------------------------------------------------------------------------- | ----------------- |
|
||||
| `@angular/bazel` | [`Bazel builder and schematics`](#bazelbuilder) | v10 |
|
||||
| `@angular/common` | [`ReflectiveInjector`](#reflectiveinjector) | <!--v8--> v11 |
|
||||
| `@angular/common` | [`CurrencyPipe` - `DEFAULT_CURRENCY_CODE`](api/common/CurrencyPipe#currency-code-deprecation) | <!--v9--> v11 |
|
||||
| `@angular/core` | [`CollectionChangeRecord`](#core) | <!--v7--> v11 |
|
||||
@ -59,7 +60,7 @@ v9 - v12
|
||||
| `@angular/core/testing` | [`TestBed.get`](#testing) | <!--v9--> v12 |
|
||||
| `@angular/router` | [`ActivatedRoute` params and `queryParams` properties](#activatedroute-props) | unspecified |
|
||||
| template syntax | [`/deep/`, `>>>`, and `::ng-deep`](#deep-component-style-selector) | <!--v7--> unspecified |
|
||||
| browser support | [`IE 9 and 10`](#ie-9-10) | <!--v10--> v11 |
|
||||
| browser support | [`IE 9 and 10, IE mobile`](#ie-9-10-and-mobile) | <!--v10--> v11 |
|
||||
|
||||
|
||||
|
||||
@ -160,7 +161,11 @@ Tip: In the [API reference section](api) of this doc site, deprecated APIs are i
|
||||
|
||||
This section lists all of the currently-deprecated features, which includes template syntax, configuration options, and any other deprecations not listed in the [Deprecated APIs](#deprecated-apis) section above. It also includes deprecated API usage scenarios or API combinations, to augment the information above.
|
||||
|
||||
{@a bazelbuilder}
|
||||
### Bazel builder and schematics
|
||||
|
||||
Bazel builder and schematics were introduced in Angular Labs to let users try out Bazel without having to manage Bazel version and BUILD files.
|
||||
This feature has been deprecated. For more information, please refer to the [migration doc](https://github.com/angular/angular/blob/master/packages/bazel/src/schematics/README.md).
|
||||
|
||||
{@a wtf}
|
||||
### Web Tracing Framework integration
|
||||
@ -459,17 +464,17 @@ export class MyModule {
|
||||
```
|
||||
|
||||
|
||||
{@a ie-9-10}
|
||||
### IE 9 and 10 support
|
||||
{@a ie-9-10-and-mobile}
|
||||
### IE 9, 10, and IE mobile support
|
||||
|
||||
Support for IE 9 and 10 has been deprecated and will be removed in a future version.
|
||||
Support for IE 9 and 10 has been deprecated, as well as support for IE Mobile. These will be dropped in a future version.
|
||||
Supporting outdated browsers like these increases bundle size, code complexity, and test load, and also requires time and effort that could be spent on improvements to the framework.
|
||||
For example, fixing issues can be more difficult, as a straightforward fix for modern browsers could break old ones that have quirks due to not receiving updates from vendors.
|
||||
|
||||
The final decision was made on three key points:
|
||||
* __Vendor support__: Microsoft dropped support of IE 9 and 10 on 1/12/16, meaning they no longer provide security updates or technical support.
|
||||
* __Usage statistics__: We looked at usage trends for IE 9 and 10 from various sources and all indicated that usage percentages were extremely small (fractions of 1%).
|
||||
* __Feedback from partners__: We also reached out to some of our Angular customers and none expressed concern about dropping IE 9 and 10 support.
|
||||
* __Vendor support__: Microsoft dropped support of IE 9 and 10 on 1/12/16, meaning they no longer provide security updates or technical support. Additionally, Microsoft dropped support for of Windows 10 Mobile in December 2019.
|
||||
* __Usage statistics__: We looked at usage trends for IE 9 and 10 (as well as IE Mobile) from various sources and all indicated that usage percentages were extremely small (fractions of 1%).
|
||||
* __Feedback from partners__: We also reached out to some of our Angular customers and none expressed concern about dropping IE 9, 10, nor IE Mobile support.
|
||||
|
||||
|
||||
{@a wrapped-value}
|
||||
|
@ -628,11 +628,6 @@
|
||||
"title": "Building & Serving",
|
||||
"tooltip": "Building and serving Angular apps."
|
||||
},
|
||||
{
|
||||
"url": "guide/bazel",
|
||||
"title": "Building with Bazel",
|
||||
"tooltip": "How to set up your environment to build and test with Bazel."
|
||||
},
|
||||
{
|
||||
"url": "guide/testing",
|
||||
"title": "Testing",
|
||||
|
@ -18,6 +18,7 @@
|
||||
{"type": 301, "source": "/docs/*/latest/quickstart.html", "destination": "/start"},
|
||||
{"type": 301, "source": "/docs/*/latest/guide/server-communication.html", "destination": "/guide/http"},
|
||||
{"type": 301, "source": "/docs/*/latest/guide/style-guide.html", "destination": "/guide/styleguide"},
|
||||
{"type": 301, "source": "/guide/bazel", "destination": "https://github.com/angular/angular/blob/master/packages/bazel/src/schematics/README.md"},
|
||||
{"type": 301, "source": "/guide/cli-quickstart", "destination": "/start"},
|
||||
{"type": 301, "source": "/guide/service-worker-getstart", "destination": "/guide/service-worker-getting-started"},
|
||||
{"type": 301, "source": "/guide/service-worker-comm", "destination": "/guide/service-worker-communications"},
|
||||
|
@ -94,6 +94,7 @@
|
||||
"!/api/testing/**",
|
||||
"!/docs/?*",
|
||||
"!/docs/*/**",
|
||||
"!/guide/bazel",
|
||||
"!/guide/change-log",
|
||||
"!/getting-started",
|
||||
"!/getting-started.html",
|
||||
|
@ -23,7 +23,7 @@
|
||||
"build-local-with-viewengine": "yarn ~~build",
|
||||
"prebuild-local-with-viewengine-ci": "node scripts/switch-to-viewengine && yarn setup-local-ci",
|
||||
"build-local-with-viewengine-ci": "yarn ~~build --progress=false",
|
||||
"extract-cli-command-docs": "node tools/transforms/cli-docs-package/extract-cli-commands.js 200a21f8a",
|
||||
"extract-cli-command-docs": "node tools/transforms/cli-docs-package/extract-cli-commands.js 14af4e07c",
|
||||
"lint": "yarn check-env && yarn docs-lint && ng lint && yarn example-lint && yarn tools-lint",
|
||||
"test": "yarn check-env && ng test",
|
||||
"pree2e": "yarn check-env && yarn update-webdriver",
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,9 +1,9 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
*/
|
||||
|
||||
export const x = 100;
|
||||
export const x = 100;
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
@ -44,4 +44,4 @@ function createPackage(tutorialName) {
|
||||
}
|
||||
|
||||
|
||||
module.exports = { createPackage };
|
||||
module.exports = { createPackage };
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
@ -43,4 +43,4 @@ function createPackage(guideName) {
|
||||
});
|
||||
}
|
||||
|
||||
module.exports = { createPackage };
|
||||
module.exports = { createPackage };
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
@ -39,4 +39,4 @@ function createPackage() {
|
||||
}
|
||||
|
||||
|
||||
module.exports = { createPackage };
|
||||
module.exports = { createPackage };
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
@ -44,4 +44,4 @@ function createPackage(tutorialName) {
|
||||
}
|
||||
|
||||
|
||||
module.exports = { createPackage };
|
||||
module.exports = { createPackage };
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
@ -34,11 +34,11 @@ var CIconfiguration = {
|
||||
'Android10': {unitTest: {target: 'SL', required: true}, e2e: {target: null, required: true}},
|
||||
// Disable all Safari and iOS tests because of incorrect results
|
||||
// ex:
|
||||
// Mobile Safari 13.0.0 (iOS 13.0.0) styling static template only should capture static values in TStylingKey FAILED
|
||||
// Expected $.content = 'dynamic' to equal '"dynamic"'.
|
||||
// Mobile Safari 12.0.0 (iOS 12.0.0) styling should handle values wrapped into SafeValue FAILED
|
||||
// Expected 'url("http://angular-ci.local:9876/1.png")' to contain 'url("/1.png")'.s
|
||||
// Tracking in: https://github.com/angular/angular/issues/36975
|
||||
// Mobile Safari 13.0.0 (iOS 13.0.0) styling static template only should capture static values in
|
||||
// TStylingKey FAILED Expected $.content = 'dynamic' to equal '"dynamic"'. Mobile Safari 12.0.0
|
||||
// (iOS 12.0.0) styling should handle values wrapped into SafeValue FAILED Expected
|
||||
// 'url("http://angular-ci.local:9876/1.png")' to contain 'url("/1.png")'.s Tracking in:
|
||||
// https://github.com/angular/angular/issues/36975
|
||||
'Safari12': {unitTest: {target: 'SL', required: false}, e2e: {target: null, required: true}},
|
||||
'Safari13': {unitTest: {target: 'SL', required: false}, e2e: {target: null, required: true}},
|
||||
'iOS12': {unitTest: {target: 'SL', required: false}, e2e: {target: null, required: true}},
|
||||
@ -152,17 +152,12 @@ var sauceAliases = {
|
||||
return customLaunchers[item].base == 'SauceLabs';
|
||||
}),
|
||||
'DESKTOP': [
|
||||
'SL_CHROME', 'SL_FIREFOX', 'SL_IE9', 'SL_IE10', 'SL_IE11', 'SL_EDGE', 'SL_SAFARI12', 'SL_SAFARI13', 'SL_FIREFOXESR'
|
||||
],
|
||||
'MOBILE': [
|
||||
'SL_ANDROID7', 'SL_ANDROID8', 'SL_ANDROID9', 'SL_ANDROID10', 'SL_IOS12', 'SL_IOS13'
|
||||
],
|
||||
'ANDROID': [
|
||||
'SL_ANDROID7', 'SL_ANDROID8', 'SL_ANDROID9', 'SL_ANDROID10'
|
||||
],
|
||||
'FIREFOX': [
|
||||
'SL_FIREFOXESR'
|
||||
'SL_CHROME', 'SL_FIREFOX', 'SL_IE9', 'SL_IE10', 'SL_IE11', 'SL_EDGE', 'SL_SAFARI12',
|
||||
'SL_SAFARI13', 'SL_FIREFOXESR'
|
||||
],
|
||||
'MOBILE': ['SL_ANDROID7', 'SL_ANDROID8', 'SL_ANDROID9', 'SL_ANDROID10', 'SL_IOS12', 'SL_IOS13'],
|
||||
'ANDROID': ['SL_ANDROID7', 'SL_ANDROID8', 'SL_ANDROID9', 'SL_ANDROID10'],
|
||||
'FIREFOX': ['SL_FIREFOXESR'],
|
||||
'IE': ['SL_IE9', 'SL_IE10', 'SL_IE11'],
|
||||
'IOS': ['SL_IOS12', 'SL_IOS13'],
|
||||
'SAFARI': ['SL_SAFARI12', 'SL_SAFARI13'],
|
||||
@ -177,11 +172,14 @@ var browserstackAliases = {
|
||||
return customLaunchers[item].base == 'BrowserStack';
|
||||
}),
|
||||
'DESKTOP': [
|
||||
'BS_CHROME', 'BS_FIREFOX', 'BS_IE9', 'BS_IE10', 'BS_IE11', 'BS_EDGE',
|
||||
],
|
||||
'MOBILE': [
|
||||
'BS_ANDROID7', 'BS_WINDOWSPHONE'
|
||||
'BS_CHROME',
|
||||
'BS_FIREFOX',
|
||||
'BS_IE9',
|
||||
'BS_IE10',
|
||||
'BS_IE11',
|
||||
'BS_EDGE',
|
||||
],
|
||||
'MOBILE': ['BS_ANDROID7', 'BS_WINDOWSPHONE'],
|
||||
'ANDROID': ['BS_ANDROID7'],
|
||||
'IE': ['BS_IE9', 'BS_IE10', 'BS_IE11'],
|
||||
'IOS': [],
|
||||
|
@ -1,7 +1,7 @@
|
||||
#!/usr/bin/env node
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,7 +1,7 @@
|
||||
#!/usr/bin/env ts-node
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -11,6 +11,7 @@ ts_library(
|
||||
"@npm//@octokit/rest",
|
||||
"@npm//@types/inquirer",
|
||||
"@npm//@types/node",
|
||||
"@npm//@types/semver",
|
||||
"@npm//@types/yargs",
|
||||
"@npm//chalk",
|
||||
],
|
||||
|
68
dev-infra/pr/merge/determine-merge-branches.ts
Normal file
68
dev-infra/pr/merge/determine-merge-branches.ts
Normal file
@ -0,0 +1,68 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
*/
|
||||
|
||||
import * as semver from 'semver';
|
||||
import {exec} from '../../utils/shelljs';
|
||||
|
||||
/**
|
||||
* Helper function that can be used to determine merge branches based on a given
|
||||
* project version. The function determines merge branches primarily through the
|
||||
* specified version, but falls back to consulting the NPM registry when needed.
|
||||
*
|
||||
* Consulting the NPM registry for determining the patch branch may slow down merging,
|
||||
* so whenever possible, the branches are determined statically based on the current
|
||||
* version. In some cases, consulting the NPM registry is inevitable because for major
|
||||
* pre-releases, we cannot determine the latest stable minor version from the current
|
||||
* pre-release version.
|
||||
*/
|
||||
export function determineMergeBranches(
|
||||
currentVersion: string, npmPackageName: string): {minor: string, patch: string} {
|
||||
const projectVersion = semver.parse(currentVersion);
|
||||
if (projectVersion === null) {
|
||||
throw Error('Cannot parse version set in project "package.json" file.');
|
||||
}
|
||||
const {major, minor, patch, prerelease} = projectVersion;
|
||||
const isMajor = minor === 0 && patch === 0;
|
||||
const isMinor = minor !== 0 && patch === 0;
|
||||
|
||||
// If there is no prerelease, then we compute patch and minor branches based
|
||||
// on the current version major and minor.
|
||||
if (prerelease.length === 0) {
|
||||
return {minor: `${major}.x`, patch: `${major}.${minor}.x`};
|
||||
}
|
||||
|
||||
// If current version is set to a minor prerelease, we can compute the merge branches
|
||||
// statically. e.g. if we are set to `9.3.0-next.0`, then our merge branches should
|
||||
// be set to `9.x` and `9.2.x`.
|
||||
if (isMinor) {
|
||||
return {minor: `${major}.x`, patch: `${major}.${minor - 1}.x`};
|
||||
} else if (!isMajor) {
|
||||
throw Error('Unexpected version. Cannot have prerelease for patch version.');
|
||||
}
|
||||
|
||||
// If we are set to a major prerelease, we cannot statically determine the stable patch
|
||||
// branch (as the latest minor segment is unknown). We determine it by looking in the NPM
|
||||
// registry for the latest stable release that will tell us about the current minor segment.
|
||||
// e.g. if the current major is `v10.0.0-next.0`, then we need to look for the latest release.
|
||||
// Let's say this is `v9.2.6`. Our patch branch will then be called `9.2.x`.
|
||||
const latestVersion = exec(`yarn -s info ${npmPackageName} dist-tags.latest`).trim();
|
||||
if (!latestVersion) {
|
||||
throw Error('Could not determine version of latest release.');
|
||||
}
|
||||
const expectedMajor = major - 1;
|
||||
const parsedLatestVersion = semver.parse(latestVersion);
|
||||
if (parsedLatestVersion === null) {
|
||||
throw Error(`Could not parse latest version from NPM registry: ${latestVersion}`);
|
||||
} else if (parsedLatestVersion.major !== expectedMajor) {
|
||||
throw Error(
|
||||
`Expected latest release to have major version: v${expectedMajor}, ` +
|
||||
`but got: v${latestVersion}`);
|
||||
}
|
||||
|
||||
return {patch: `${expectedMajor}.${parsedLatestVersion.minor}.x`, minor: `${expectedMajor}.x`};
|
||||
}
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -16,6 +16,7 @@
|
||||
"inquirer": "<from-root>",
|
||||
"minimatch": "<from-root>",
|
||||
"multimatch": "<from-root>",
|
||||
"semver": "<from-root>",
|
||||
"shelljs": "<from-root>",
|
||||
"typed-graphqlify": "<from-root>",
|
||||
"yaml": "<from-root>",
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,7 +1,7 @@
|
||||
#!/usr/bin/env node
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
@ -37,7 +37,7 @@ export type NgDevConfig<T = {}> = CommonConfig&T;
|
||||
* The filename expected for creating the ng-dev config, without the file
|
||||
* extension to allow either a typescript or javascript file to be used.
|
||||
*/
|
||||
const CONFIG_FILE_NAME = '.ng-dev-config';
|
||||
const CONFIG_FILE_PATH = '.ng-dev/config';
|
||||
|
||||
/** The configuration for ng-dev. */
|
||||
let CONFIG: {}|null = null;
|
||||
@ -50,7 +50,7 @@ export function getConfig(): NgDevConfig {
|
||||
// If the global config is not defined, load it from the file system.
|
||||
if (CONFIG === null) {
|
||||
// The full path to the configuration file.
|
||||
const configPath = join(getRepoBaseDir(), CONFIG_FILE_NAME);
|
||||
const configPath = join(getRepoBaseDir(), CONFIG_FILE_PATH);
|
||||
// Set the global config object.
|
||||
CONFIG = readConfigFile(configPath);
|
||||
}
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -7,7 +7,7 @@ As a contributor, see the instructions in [CONTRIBUTING.md](../CONTRIBUTING.md).
|
||||
|
||||
# Change approvals
|
||||
|
||||
Change approvals in our monorepo are managed via [PullApprove](https://https://docs.pullapprove.com/) and are configured via the [`.pullapprove`](../.pullapprove) file.
|
||||
Change approvals in our monorepo are managed via [PullApprove](https://docs.pullapprove.com/) and are configured via the [`.pullapprove`](../.pullapprove) file.
|
||||
|
||||
# Merging
|
||||
|
||||
|
@ -61,8 +61,8 @@
|
||||
"bundle": "TODO(i): temporarily increase the payload size limit from 105779 - this is due to a closure issue related to ESM reexports that still needs to be investigated",
|
||||
"bundle": "TODO(i): we should define ngDevMode to false in Closure, but --define only works in the global scope.",
|
||||
"bundle": "TODO(i): (FW-2164) TS 3.9 new class shape seems to have broken Closure in big ways. The size went from 169991 to 252338",
|
||||
"bundle": "TODO(i): after removal of tsickle from ngc-wrapped / ng_package, we had to switch to SIMPLE optimizations which increased the size from 252338 to 1218969, see PR#37221 for more info",
|
||||
"bundle": 1218969
|
||||
"bundle": "TODO(i): after removal of tsickle from ngc-wrapped / ng_package, we had to switch to SIMPLE optimizations which increased the size from 252338 to 1200475, see PR#37221 and PR#37317 for more info",
|
||||
"bundle": 1200475
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -33,15 +33,6 @@ INTEGRATION_TESTS = {
|
||||
"no-ivy-aot",
|
||||
],
|
||||
},
|
||||
"bazel-schematics": {
|
||||
"tags": [
|
||||
# Bazel-in-bazel tests are resource intensive and should not be over-parallized
|
||||
# as they will complete for the resources of other parallel tests slowing
|
||||
# everything down. Ask Bazel to allocate multiple CPUs for these tests with "cpu:n" tag.
|
||||
"cpu:3",
|
||||
"no-ivy-aot",
|
||||
],
|
||||
},
|
||||
"cli-hello-world": {"commands": "payload_size_tracking"},
|
||||
"cli-hello-world-ivy-compat": {"commands": "payload_size_tracking"},
|
||||
"cli-hello-world-ivy-i18n": {
|
||||
|
@ -1,4 +1,4 @@
|
||||
# Copyright Google Inc. All Rights Reserved.
|
||||
# Copyright Google LLC All Rights Reserved.
|
||||
#
|
||||
# Use of this source code is governed by an MIT-style license that can be
|
||||
# found in the LICENSE file at https://angular.io/license
|
||||
|
1
integration/bazel-schematics/.gitignore
vendored
1
integration/bazel-schematics/.gitignore
vendored
@ -1 +0,0 @@
|
||||
/demo
|
@ -1,35 +0,0 @@
|
||||
{
|
||||
"name": "bazel-schematics",
|
||||
"version": "1.0.0",
|
||||
"main": "index.js",
|
||||
"license": "MIT",
|
||||
"devDependencies": {
|
||||
"@angular-devkit/build-angular": "file:../../node_modules/@angular-devkit/build-angular",
|
||||
"@angular/animations": "file:../../dist/packages-dist/animations",
|
||||
"@angular/bazel": "file:../../dist/packages-dist/bazel",
|
||||
"@angular/cli": "file:../../node_modules/@angular/cli",
|
||||
"@angular/common": "file:../../dist/packages-dist/common",
|
||||
"@angular/compiler": "file:../../dist/packages-dist/compiler",
|
||||
"@angular/compiler-cli": "file:../../dist/packages-dist/compiler-cli",
|
||||
"@angular/core": "file:../../dist/packages-dist/core",
|
||||
"@angular/forms": "file:../../dist/packages-dist/forms",
|
||||
"@angular/language-service": "file:../../dist/packages-dist/language-service",
|
||||
"@angular/platform-browser": "file:../../dist/packages-dist/platform-browser",
|
||||
"@angular/platform-browser-dynamic": "file:../../dist/packages-dist/platform-browser-dynamic",
|
||||
"@angular/router": "file:../../dist/packages-dist/router",
|
||||
"@types/node": "file:../../node_modules/@types/node",
|
||||
"patch-package": "^6.2.1",
|
||||
"protractor": "file:../../node_modules/protractor",
|
||||
"puppeteer": "file:../../node_modules/puppeteer",
|
||||
"typescript": "file:../../node_modules/typescript",
|
||||
"tslib": "file:../../node_modules/tslib"
|
||||
},
|
||||
"//resolutions-comment": "Ensure a single version of webdriver-manager which comes from root node_modules that has already run webdriver-manager update",
|
||||
"resolutions": {
|
||||
"**/webdriver-manager": "file:../../node_modules/webdriver-manager"
|
||||
},
|
||||
"scripts": {
|
||||
"test": "./test.sh",
|
||||
"postinstall": "patch-package"
|
||||
}
|
||||
}
|
@ -1,25 +0,0 @@
|
||||
diff --git a/node_modules/@angular/bazel/src/builders/files/WORKSPACE.template b/node_modules/@angular/bazel/src/builders/files/WORKSPACE.template
|
||||
index 9aad043..e767dc6 100755
|
||||
--- a/node_modules/@angular/bazel/src/builders/files/WORKSPACE.template
|
||||
+++ b/node_modules/@angular/bazel/src/builders/files/WORKSPACE.template
|
||||
@@ -10,7 +10,7 @@
|
||||
# imports also make sense when referencing the published package.
|
||||
workspace(
|
||||
name = "project",
|
||||
- managed_directories = {"@npm": ["node_modules"]},
|
||||
+ # managed_directories = {"@npm": ["node_modules"]},
|
||||
)
|
||||
|
||||
load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
|
||||
@@ -67,6 +67,11 @@ node_repositories(
|
||||
yarn_install(
|
||||
name = "npm",
|
||||
package_json = "//:package.json",
|
||||
+ # Turn off symlink_node_modules here as it causes flakiness with missing
|
||||
+ # files in node_modules.
|
||||
+ # TODO: track down the root cause of the flakiness; current suspect is that
|
||||
+ # it is an issue with managed_directories when resources are limited
|
||||
+ symlink_node_modules = False,
|
||||
yarn_lock = "//:yarn.lock",
|
||||
)
|
||||
|
@ -1,94 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
set -eux -o pipefail
|
||||
|
||||
# sedi makes `sed -i` work on both OSX & Linux
|
||||
# See https://stackoverflow.com/questions/2320564/i-need-my-sed-i-command-for-in-place-editing-to-work-with-both-gnu-sed-and-bsd
|
||||
function sedi () {
|
||||
case $(uname) in
|
||||
Darwin*) sedi=('-i' '') ;;
|
||||
*) sedi='-i' ;;
|
||||
esac
|
||||
|
||||
sed "${sedi[@]}" "$@"
|
||||
}
|
||||
|
||||
function installLocalPackages() {
|
||||
# Install Angular packages that are built locally from HEAD.
|
||||
# This also gets around the bug whereby yarn caches local `file://` urls.
|
||||
# See https://github.com/yarnpkg/yarn/issues/2165
|
||||
readonly pwd=$(pwd)
|
||||
readonly packages=(
|
||||
animations common compiler core forms platform-browser
|
||||
platform-browser-dynamic router bazel compiler-cli language-service
|
||||
)
|
||||
local local_packages=()
|
||||
for package in "${packages[@]}"; do
|
||||
local_packages+=("@angular/${package}@file:${pwd}/../node_modules/@angular/${package}")
|
||||
done
|
||||
|
||||
# keep protractor, typescript, tslib, and @types/node versions in sync with the ones used in this repo
|
||||
local_packages+=("protractor@file:${pwd}/../node_modules/protractor")
|
||||
local_packages+=("typescript@file:${pwd}/../node_modules/typescript")
|
||||
local_packages+=("tslib@file:${pwd}/../node_modules/tslib")
|
||||
local_packages+=("@types/node@file:${pwd}/../node_modules/@types/node")
|
||||
|
||||
# add protractor, puppeteer & webdriver-manager so we get the chrome & chromedriver binaries
|
||||
# that have already been downloaded at the root
|
||||
local_packages+=("puppeteer@file:${pwd}/../node_modules/puppeteer")
|
||||
local_packages+=("webdriver-manager@file:${pwd}/../node_modules/webdriver-manager")
|
||||
|
||||
yarn add --ignore-scripts --silent "${local_packages[@]}" --cache-folder ./.yarn_local_cache
|
||||
}
|
||||
|
||||
function patchKarmaConf() {
|
||||
sedi "s#module.exports#process.env.CHROME_BIN = require\('puppeteer'\).executablePath\(\); module.exports#" ./karma.conf.js
|
||||
sedi "s#browsers\: \['Chrome'\],#customLaunchers\: \{ ChromeHeadlessNoSandbox\: \{ base\: 'ChromeHeadless', flags\: \['--no-sandbox', '--headless', '--disable-gpu', '--disable-dev-shm-usage', '--hide-scrollbars', '--mute-audio'\] \} \}, browsers\: \['ChromeHeadlessNoSandbox'\],#" ./karma.conf.js
|
||||
}
|
||||
|
||||
function patchProtractorConf() {
|
||||
sedi "s#browserName\: 'chrome'#browserName\: 'chrome', chromeOptions\: \{ binary: require\('puppeteer'\).executablePath\(\), args: \['--no-sandbox', '--headless', '--disable-gpu', '--disable-dev-shm-usage', '--hide-scrollbars', '--mute-audio'\] \},#" ./e2e/protractor.conf.js
|
||||
}
|
||||
|
||||
function testBazel() {
|
||||
# Set up
|
||||
ng version
|
||||
rm -rf demo
|
||||
# Create project
|
||||
ng new demo --collection=@angular/bazel --routing --skip-git --skip-install --style=scss
|
||||
cd demo
|
||||
# Use a local yarn cache folder so we don't access the global yarn cache
|
||||
mkdir .yarn_local_cache
|
||||
patchKarmaConf
|
||||
patchProtractorConf
|
||||
installLocalPackages
|
||||
ng generate component widget --style=css
|
||||
ng build
|
||||
ng test
|
||||
ng e2e
|
||||
ng e2e --prod
|
||||
if [ -e 'WORKSPACE' ] || [ -e 'BUILD.bazel' ]; then
|
||||
echo 'WORKSPACE / BUILD.bazel file should not exist in project'
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
|
||||
function testNonBazel() {
|
||||
# Replace angular.json that uses Bazel builder with the default generated by CLI
|
||||
mv ./angular.json.bak ./angular.json
|
||||
rm -rf dist src/main.dev.ts src/main.prod.ts
|
||||
# disable CLI's version check (if version is 0.0.0, then no version check happens)
|
||||
yarn --cwd node_modules/@angular/cli version --new-version 0.0.0 --no-git-tag-version
|
||||
# re-add build-angular
|
||||
yarn add --dev file:../node_modules/@angular-devkit/build-angular --cache-folder ./.yarn_local_cache
|
||||
ng build --progress=false
|
||||
ng test --progress=false --watch=false
|
||||
ng e2e --port 0 --configuration=production --webdriver-update=false
|
||||
}
|
||||
|
||||
testBazel
|
||||
|
||||
# this test verifies that users can undo bazel - the value of this is questionable
|
||||
# because there are way too many manual steps and it would be easier for users to
|
||||
# just revert the diff created by `ng add @angular/bazel`
|
||||
testNonBazel
|
File diff suppressed because it is too large
Load Diff
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -90,13 +90,9 @@ assertSucceeded "Expected 'ngcc' to log 'Compiling'."
|
||||
grep "ApplicationModule.ɵmod = ɵngcc0.ɵɵdefineNgModule" node_modules/@angular/core/esm2015/src/application_module.js
|
||||
assertSucceeded "Expected 'ngcc' to correctly compile 'ApplicationModule' in '@angular/core' (esm2015)."
|
||||
|
||||
# TODO: This assertion is disabled because @angular/core is no longer processed by tsickle which creates the static properties.
|
||||
# We should either remove this assertion or use a syntentic JS file as input.
|
||||
# Discuss with the ngcc folks.
|
||||
#
|
||||
# Did it place the `setClassMetadata` call correctly?
|
||||
# cat node_modules/@angular/core/fesm2015/core.js | awk 'ORS=" "' | grep "ApplicationRef.ctorParameters.*setClassMetadata(ApplicationRef"
|
||||
# assertSucceeded "Expected 'ngcc' to place 'setClassMetadata' after static properties like 'ctorParameters' in '@angular/core' (fesm2015)."
|
||||
cat node_modules/@angular/core/fesm2015/core.js | awk 'ORS=" "' | grep "ApplicationRef.ctorParameters.*setClassMetadata(ApplicationRef"
|
||||
assertSucceeded "Expected 'ngcc' to place 'setClassMetadata' after static properties like 'ctorParameters' in '@angular/core' (fesm2015)."
|
||||
|
||||
|
||||
# Did it transform @angular/core typing files correctly?
|
||||
@ -123,13 +119,19 @@ assertSucceeded "Expected 'ngcc' to log 'Compiling'."
|
||||
assertSucceeded "Expected 'ngcc' to generate an abstract directive definition for 'MatMenuBase' in '@angular/material' (esm5)."
|
||||
|
||||
|
||||
# TODO: This assertion is disabled because @angular/common no longer contains __decorate calls.
|
||||
# We should either remove this assertion or use a syntentic JS file as input.
|
||||
# Discuss with the ngcc folks.
|
||||
# Did it handle namespace imported decorators in UMD using `__decorate` syntax?
|
||||
grep "type: i0.Injectable" node_modules/@angular/common/bundles/common.umd.js
|
||||
assertSucceeded "Expected 'ngcc' to correctly handle '__decorate' syntax in '@angular/common' (umd)."
|
||||
#grep "type: i0.Injectable" node_modules/@angular/common/bundles/common.umd.js
|
||||
#assertSucceeded "Expected 'ngcc' to correctly handle '__decorate' syntax in '@angular/common' (umd)."
|
||||
|
||||
# TODO: This assertion is disabled because @angular/common no longer contains __decorate calls.
|
||||
# We should either remove this assertion or use a syntentic JS file as input.
|
||||
# Discuss with the ngcc folks.
|
||||
# (and ensure the @angular/common package is indeed using `__decorate` syntax)
|
||||
grep "JsonPipe = __decorate(" node_modules/@angular/common/bundles/common.umd.js.__ivy_ngcc_bak
|
||||
assertSucceeded "Expected '@angular/common' (umd) to actually use '__decorate' syntax."
|
||||
#grep "JsonPipe = __decorate(" node_modules/@angular/common/bundles/common.umd.js.__ivy_ngcc_bak
|
||||
#assertSucceeded "Expected '@angular/common' (umd) to actually use '__decorate' syntax."
|
||||
|
||||
|
||||
# Did it handle namespace imported decorators in UMD using static properties?
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,6 +1,6 @@
|
||||
/**
|
||||
* @license
|
||||
* Copyright Google Inc. All Rights Reserved.
|
||||
* Copyright Google LLC All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by an MIT-style license that can be
|
||||
* found in the LICENSE file at https://angular.io/license
|
||||
|
@ -1,5 +1,3 @@
|
||||
import "tslib";
|
||||
|
||||
import "@angular/animations";
|
||||
|
||||
import "@angular/core";
|
||||
|
@ -1,3 +1 @@
|
||||
import "tslib";
|
||||
|
||||
import "@angular/core";
|
||||
|
@ -1,7 +1,5 @@
|
||||
import "rxjs";
|
||||
|
||||
import "tslib";
|
||||
|
||||
import "rxjs/operators";
|
||||
|
||||
const __globalThis = "undefined" !== typeof globalThis && globalThis;
|
||||
|
@ -1,5 +1,3 @@
|
||||
import "tslib";
|
||||
|
||||
import "@angular/core";
|
||||
|
||||
import "@angular/common";
|
||||
|
@ -1,5 +1,3 @@
|
||||
import "tslib";
|
||||
|
||||
import "@angular/common";
|
||||
|
||||
import "@angular/core";
|
||||
|
@ -1,5 +1,3 @@
|
||||
import "tslib";
|
||||
|
||||
import "@angular/common";
|
||||
|
||||
import "@angular/core";
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user