refactor(bazel): Remove bazel-workspace schematics (#29148)

`bazel-workspace` schematics is no longer needed now that the Bazel
files are injected into the project by the Bazel builder.

PR Close #29148
This commit is contained in:
Keen Yee Liau
2019-03-06 17:50:57 -08:00
committed by Kara Erickson
parent 36a1550e00
commit f4f20daee3
29 changed files with 127 additions and 663 deletions

View File

@ -61,20 +61,13 @@ function addDevDependenciesToPackageJson(options: Schema) {
}
/**
* Append main.dev.ts and main.prod.ts to src directory. These files are needed
* by Bazel for devserver and prodserver, respectively. They are different from
* main.ts generated by CLI because they use platformBrowser (AOT) instead of
* platformBrowserDynamic (JIT).
* Append additional Javascript / Typescript files needed to compile an Angular
* project under Bazel.
*/
function addDevAndProdMainForAot(options: Schema) {
function addFilesRequiredByBazel(options: Schema) {
return (host: Tree) => {
return mergeWith(apply(url('./files'), [
applyTemplates({
utils: strings,
...options,
'dot': '.',
}),
move('/src'),
applyTemplates({}),
]));
};
}
@ -331,8 +324,7 @@ export default function(options: Schema): Rule {
validateProjectName(options.name);
return chain([
schematic('bazel-workspace', options),
addDevAndProdMainForAot(options),
addFilesRequiredByBazel(options),
addDevDependenciesToPackageJson(options),
addPostinstallToGenerateNgSummaries(),
backupAngularJson(),