mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-19 00:41:43 +00:00
[bazel] Use WPILIB_VERSION automatically for version template generation (#8117)
This commit is contained in:
@@ -1,9 +1,10 @@
|
||||
def _generate_version_file_impl(ctx):
|
||||
out = ctx.actions.declare_file(ctx.attr.output_file)
|
||||
wpilib_version = ctx.var.get("WPILIB_VERSION")
|
||||
ctx.actions.expand_template(
|
||||
output = out,
|
||||
template = ctx.file.template,
|
||||
substitutions = {"${wpilib_version}": "TODO - Built with bazel"},
|
||||
substitutions = {"${wpilib_version}": wpilib_version},
|
||||
)
|
||||
return [DefaultInfo(files = depset([out]))]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user