From d73c7162dfd7b5bc9de7d0e9594fa27887d899db Mon Sep 17 00:00:00 2001 From: Paul Gschwendtner Date: Wed, 15 Dec 2021 16:16:29 +0100 Subject: [PATCH] build: add postinstall script as runfile for `yarn_install` repository rule (#44490) Adds the postinstall script as runfile for the `yarn_install` repository rule, so that the dependencies are re-fetched when the script changes. PR Close #44490 --- WORKSPACE | 3 +++ tools/BUILD.bazel | 1 + 2 files changed, 4 insertions(+) diff --git a/WORKSPACE b/WORKSPACE index 52f8955d0a8..8bec487b1e7 100644 --- a/WORKSPACE +++ b/WORKSPACE @@ -40,6 +40,9 @@ load("//integration:npm_package_archives.bzl", "npm_package_archives") yarn_install( name = "npm", + # Note that we add the postinstall script here so that the dependencies are re-installed + # when the postinstall patches are modified. + data = ["//tools:postinstall-patches.js"], manual_build_file_contents = npm_package_archives(), package_json = "//:package.json", yarn_lock = "//:yarn.lock", diff --git a/tools/BUILD.bazel b/tools/BUILD.bazel index 507124d6604..e3b52d14281 100644 --- a/tools/BUILD.bazel +++ b/tools/BUILD.bazel @@ -4,6 +4,7 @@ package(default_visibility = ["//visibility:public"]) exports_files([ "tsconfig.json", + "postinstall-patches.js", "jasmine-seed-generator.js", ])