mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-19 00:41:43 +00:00
[robotpy][examples] Split examples and snippets (#8944)
This also updates the bazel scripts to behave more like the C++ and Java examples, and updates the copybara scripts to be able to sync up `mostrobotpy`
This commit is contained in:
@@ -2,7 +2,7 @@ load("@allwpilib_pip_deps//:requirements.bzl", "requirement")
|
||||
load("@aspect_bazel_lib//lib:write_source_files.bzl", "write_source_file")
|
||||
load("@rules_python//python:defs.bzl", "py_binary")
|
||||
load("@rules_python//python/entry_points:py_console_script_binary.bzl", "py_console_script_binary")
|
||||
load(":define_examples.bzl", "define_examples")
|
||||
load(":define_examples.bzl", "define_examples", "define_snippets")
|
||||
|
||||
py_binary(
|
||||
name = "generate_bazel_files",
|
||||
@@ -22,7 +22,8 @@ cmd = "$(locations :generate_bazel_files) $(OUTS)"
|
||||
genrule(
|
||||
name = "generate_bazel_files_rule",
|
||||
srcs = [
|
||||
"examples.toml",
|
||||
"examples/examples.toml",
|
||||
"snippets/snippets.toml",
|
||||
],
|
||||
outs = ["gen/example_projects.bzl"],
|
||||
cmd = cmd,
|
||||
@@ -45,3 +46,5 @@ py_console_script_binary(
|
||||
)
|
||||
|
||||
define_examples()
|
||||
|
||||
define_snippets()
|
||||
|
||||
Reference in New Issue
Block a user