From c9621bda56d6b712a7153120deb19a6942734c7b Mon Sep 17 00:00:00 2001 From: David Ostrovsky Date: Tue, 7 Jun 2022 07:03:18 +0200 Subject: [PATCH] Bazel: Remove usage of managed_directories Bazel removed `managed_directories` feature on Bazel@HEAD, see: [1]. Design document is here: [2]. Also extend the .bazelignore and add explicitly the path to the node_modules directories. Note, that Bazel currently doesn't support the same semantic as .gitignore. For more details see this issue: [3] and this issue specific to rules_nodejs: [4]. [1] https://github.com/bazelbuild/bazel/issues/15463 [2] https://docs.google.com/document/d/1u9V5RUc7i6Urh8gGfnSurxpWA7JMRtwCi1Pr5BHeE44/edit [3] https://github.com/bazelbuild/bazel/issues/7093 [4] https://github.com/bazelbuild/bazel/issues/8106 Release-Notes: skip Change-Id: I5dc582e05e4116064fc06d438d4b8a8b57b6bb8d --- .bazelignore | 4 ++++ WORKSPACE | 7 ------- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/.bazelignore b/.bazelignore index 69c04b138fde..e19fe6ec338e 100644 --- a/.bazelignore +++ b/.bazelignore @@ -1,2 +1,6 @@ eclipse-out node_modules +polygerrit-ui/app/node_modules +polygerrit-ui/node_modules +plugins/node_modules +tools/node_tools/node_modules diff --git a/WORKSPACE b/WORKSPACE index 74016c08e15c..44993917ce2b 100644 --- a/WORKSPACE +++ b/WORKSPACE @@ -17,13 +17,6 @@ # usages of code from devDependencies in polygerrit bundle. workspace( name = "gerrit", - managed_directories = { - "@npm": ["node_modules"], - "@ui_npm": ["polygerrit-ui/app/node_modules"], - "@ui_dev_npm": ["polygerrit-ui/node_modules"], - "@tools_npm": ["tools/node_tools/node_modules"], - "@plugins_npm": ["plugins/node_modules"], - }, ) load("@bazel_tools//tools/build_defs/repo:git.bzl", "git_repository")