Philipp Schrader | cdb5cfc | 2022-02-20 14:57:07 -0800 | [diff] [blame] | 1 | load("@com_github_google_flatbuffers//:build_defs.bzl", "flatbuffer_go_library", "flatbuffer_ts_library") |
| 2 | |
Philipp Schrader | d9096a3 | 2022-02-24 17:53:09 -0800 | [diff] [blame] | 3 | FILE_NAMES = ( |
| 4 | "error_response", |
| 5 | "submit_data_scouting", |
| 6 | "submit_data_scouting_response", |
Sabina Leaver | e66c2fc | 2022-02-24 16:56:15 -0800 | [diff] [blame] | 7 | "request_all_matches", |
| 8 | "request_all_matches_response", |
| 9 | "request_matches_for_team", |
| 10 | "request_matches_for_team_response", |
| 11 | "request_data_scouting", |
| 12 | "request_data_scouting_response", |
Philipp Schrader | d3fac19 | 2022-03-02 20:35:46 -0800 | [diff] [blame^] | 13 | "refresh_match_list", |
| 14 | "refresh_match_list_response", |
Philipp Schrader | d9096a3 | 2022-02-24 17:53:09 -0800 | [diff] [blame] | 15 | ) |
| 16 | |
| 17 | filegroup( |
| 18 | name = "fbs_files", |
| 19 | srcs = ["%s.fbs" % name for name in FILE_NAMES], |
| 20 | visibility = ["//visibility:public"], |
| 21 | ) |
| 22 | |
Philipp Schrader | cdb5cfc | 2022-02-20 14:57:07 -0800 | [diff] [blame] | 23 | [( |
| 24 | flatbuffer_go_library( |
| 25 | name = name + "_go_fbs", |
| 26 | srcs = [name + ".fbs"], |
| 27 | importpath = "github.com/frc971/971-Robot-Code/scouting/webserver/requests/messages/" + name, |
| 28 | target_compatible_with = ["@platforms//cpu:x86_64"], |
| 29 | visibility = ["//visibility:public"], |
| 30 | ), |
| 31 | flatbuffer_ts_library( |
| 32 | name = name + "_ts_fbs", |
| 33 | srcs = [name + ".fbs"], |
| 34 | target_compatible_with = ["@platforms//cpu:x86_64"], |
| 35 | visibility = ["//visibility:public"], |
| 36 | ), |
Philipp Schrader | d9096a3 | 2022-02-24 17:53:09 -0800 | [diff] [blame] | 37 | ) for name in FILE_NAMES] |