Prepare for migration from ts_library to ts_project
With the upcoming migration from rules_nodejs to rules_js, I am
changing all the `ts_library` targets to become `ts_project` targets.
This patch introduces an alias for a NOP effect. A future patch will
switch the actual implementation.
I am leaving the scouting directory alone because all the build rules
will change completely. They will use Angular-specific rules.
Signed-off-by: Philipp Schrader <philipp.schrader@gmail.com>
Change-Id: I4b4fd4d14dbf25d6dbdaa3c1725ee6b651eedab6
diff --git a/y2020/control_loops/drivetrain/BUILD b/y2020/control_loops/drivetrain/BUILD
index 0455d0f..fa153f0 100644
--- a/y2020/control_loops/drivetrain/BUILD
+++ b/y2020/control_loops/drivetrain/BUILD
@@ -1,7 +1,7 @@
+load("//tools/build_rules:js.bzl", "ts_project")
load("@com_github_google_flatbuffers//:build_defs.bzl", "flatbuffer_cc_library")
load("@com_github_google_flatbuffers//:typescript.bzl", "flatbuffer_ts_library")
load("//aos:config.bzl", "aos_config")
-load("@npm//@bazel/typescript:index.bzl", "ts_library")
genrule(
name = "genrule_drivetrain",
@@ -216,7 +216,7 @@
],
)
-ts_library(
+ts_project(
name = "localizer_plotter",
srcs = ["localizer_plotter.ts"],
target_compatible_with = ["@platforms//os:linux"],
diff --git a/y2020/control_loops/superstructure/BUILD b/y2020/control_loops/superstructure/BUILD
index d3f303f..d1f20a2 100644
--- a/y2020/control_loops/superstructure/BUILD
+++ b/y2020/control_loops/superstructure/BUILD
@@ -1,6 +1,6 @@
+load("//tools/build_rules:js.bzl", "ts_project")
load("@com_github_google_flatbuffers//:build_defs.bzl", "flatbuffer_cc_library")
load("@com_github_google_flatbuffers//:typescript.bzl", "flatbuffer_ts_library")
-load("@npm//@bazel/typescript:index.bzl", "ts_library")
package(default_visibility = ["//visibility:public"])
@@ -136,7 +136,7 @@
],
)
-ts_library(
+ts_project(
name = "turret_plotter",
srcs = ["turret_plotter.ts"],
target_compatible_with = ["@platforms//os:linux"],
@@ -152,7 +152,7 @@
],
)
-ts_library(
+ts_project(
name = "finisher_plotter",
srcs = ["finisher_plotter.ts"],
target_compatible_with = ["@platforms//os:linux"],
@@ -163,7 +163,7 @@
],
)
-ts_library(
+ts_project(
name = "accelerator_plotter",
srcs = ["accelerator_plotter.ts"],
target_compatible_with = ["@platforms//os:linux"],
@@ -174,7 +174,7 @@
],
)
-ts_library(
+ts_project(
name = "hood_plotter",
srcs = ["hood_plotter.ts"],
target_compatible_with = ["@platforms//os:linux"],
diff --git a/y2020/www/BUILD b/y2020/www/BUILD
index 8467994..0c05900 100644
--- a/y2020/www/BUILD
+++ b/y2020/www/BUILD
@@ -1,8 +1,7 @@
-load("@npm//@bazel/typescript:index.bzl", "ts_library")
-load("//tools/build_rules:js.bzl", "rollup_bundle")
+load("//tools/build_rules:js.bzl", "rollup_bundle", "ts_project")
load("//frc971/downloader:downloader.bzl", "aos_downloader_dir")
-ts_library(
+ts_project(
name = "camera_main",
srcs = [
"camera_main.ts",
@@ -21,7 +20,7 @@
],
)
-ts_library(
+ts_project(
name = "field_main",
srcs = [
"constants.ts",