build: use bazel version from node modules (#26691)

* No longer depends on a custom CircleCI docker image that comes with Bazel pre-installed. Since Bazel is now available through NPM, we should be able to use the version from `@bazel/bazel` in order to enforce a consistent environment on CI and locally.
* This also reduces the amount of packages that need to be published (ngcontainer is removed)

PR Close #26691
This commit is contained in:
Paul Gschwendtner
2018-10-27 09:25:45 +02:00
committed by Matias Niemelä
parent 66be3c9f51
commit 8fc4ae51fb
21 changed files with 214 additions and 146 deletions

View File

@ -22,4 +22,4 @@ protractor_web_test = _protractor_web_test
protractor_web_test_suite = _protractor_web_test_suite
ng_setup_workspace = _ng_setup_workspace
# DO NOT ADD PUBLIC API without including in the documentation generation
# Run `bazel build //packages/bazel/docs` to verify
# Run `yarn bazel build //packages/bazel/docs` to verify

View File

@ -87,16 +87,11 @@ def rules_angular_dev_dependencies():
url = "https://github.com/bazelbuild/bazel/archive/0.18.0.zip",
)
# This commit matches the version of buildifier in angular/ngcontainer
# If you change this, also check if it matches the version in the angular/ngcontainer
# version in /.circleci/config.yml
BAZEL_BUILDTOOLS_VERSION = "49a6c199e3fbf5d94534b2771868677d3f9c6de9"
http_archive(
name = "com_github_bazelbuild_buildtools",
sha256 = "edf39af5fc257521e4af4c40829fffe8fba6d0ebff9f4dd69a6f8f1223ae047b",
strip_prefix = "buildtools-%s" % BAZEL_BUILDTOOLS_VERSION,
url = "https://github.com/bazelbuild/buildtools/archive/%s.zip" % BAZEL_BUILDTOOLS_VERSION,
sha256 = "a82d4b353942b10c1535528b02bff261d020827c9c57e112569eddcb1c93d7f6",
strip_prefix = "buildtools-0.17.2",
url = "https://github.com/bazelbuild/buildtools/archive/0.17.2.zip",
)
#############################################

View File

@ -101,7 +101,7 @@ function runPackageGoldTest(testPackage: TestPackage) {
` Diff:\n` +
` ${patch}\n\n` +
` To accept the new golden file, run:\n` +
` bazel run ${process.env['BAZEL_TARGET']}.accept\n`;
` yarn bazel run ${process.env['BAZEL_TARGET']}.accept\n`;
fail(failureMessage);
}