Skip to content

Commit

Permalink
Add docs
Browse files Browse the repository at this point in the history
  • Loading branch information
fmeum committed Apr 18, 2023
1 parent 650ea43 commit 642ec7b
Showing 1 changed file with 30 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -126,11 +126,24 @@ public boolean isDevDependency(TypeCheckedTag tag) {

@StarlarkMethod(
name = "extension_metadata",
doc = "foo",
doc = "Constructs an opaque object that can be returned from the module extension's "
+ "implementation function to provide metadata about the repositories generated by the "
+ "extension to Bazel.",
parameters = {
@Param(
name = "root_module_direct_deps",
doc = "foo",
doc = "The names of the repositories that the extension considers to be direct "
+ "dependencies of the root module. If the root module imports additional "
+ "repositories or does not import all of these repositories via <a "
+ "href=\"../globals/module.html#use_repo\"><code>use_repo</code></a>, Bazel "
+ "will print a warning and a fixup command when the extension is evaluated."
+ "<p>If one of <code>root_module_direct_deps</code> and <code>"
+ "root_module_direct_dev_deps</code> is specified, the other has to be as well. "
+ "The lists specified by these two parameters must be disjoint."
+ "<p>Exactly one of <code>root_module_direct_deps</code> and <code>"
+ "root_module_direct_dev_deps</code> can be set to the special value <code>"
+ "\"all\"</code>, which is treated as if a list with the names of all"
+ "repositories generated by the extension was specified as the value.",
positional = false,
named = true,
defaultValue = "None",
Expand All @@ -140,7 +153,21 @@ public boolean isDevDependency(TypeCheckedTag tag) {
@ParamType(type = NoneType.class)}),
@Param(
name = "root_module_direct_dev_deps",
doc = "foo",
doc = "The names of the repositories that the extension considers to be direct "
+ "dev dependencies of the root module. If the root module imports additional "
+ "repositories or does not import all of these repositories via <a "
+ "href=\"../globals/module.html#use_repo\"><code>use_repo</code></a> on an "
+ "extension proxy created with <code><a "
+ "href=\"../globals/module.html#use_extension>use_extension</a>(..., "
+ "dev_dependency = True)</code>, Bazel will print a warning and a fixup command "
+ "when the extension is evaluated."
+ "<p>If one of <code>root_module_direct_deps</code> and <code>"
+ "root_module_direct_dev_deps</code> is specified, the other has to be as well. "
+ "The lists specified by these two parameters must be disjoint."
+ "<p>Exactly one of <code>root_module_direct_deps</code> and <code>"
+ "root_module_direct_dev_deps</code> can be set to the special value <code>"
+ "\"all\"</code>, which is treated as if a list with the names of all"
+ "repositories generated by the extension was specified as the value.",
positional = false,
named = true,
defaultValue = "None",
Expand Down

0 comments on commit 642ec7b

Please sign in to comment.