File tree Expand file tree Collapse file tree
docs/api/rules_python/command_line_option Expand file tree Collapse file tree Original file line number Diff line number Diff line change 44:::
55
66# //command_line_option
7+
8+ This package provides special targets that correspond to the Bazel-builtin
9+ ` //command_line_option ` psuedo-targets. These can be used with the {obj}` config_settings `
10+ attribute on Python rules to transition specific command line flags for a target.
11+
12+ :::{note}
13+ These targets are not actual ` alias() ` targets, nor are they the actual builtin
14+ command line flags. They are regular targets that the ` config_settings ` transition
15+ logic specially recognizes and handles as if they were the builtin ` //command_line_option `
16+ psuedo-targets.
17+ :::
18+
19+ :::{seealso}
20+ The ` config_settings ` attribute documentation on:
21+ * {obj}` py_binary.config_settings `
22+ * {obj}` py_test.config_settings `
23+ :::
24+
25+ ## build_runfile_links
26+
27+ :::{bzl: target } build_runfile_links
28+
29+ Special target for the Bazel-builtin ` //command_line_option:build_runfile_links ` flag.
30+
31+ See the [ Bazel documentation for --build_runfile_links] ( https://bazel.build/reference/command-line-reference#flag--build_runfile_links ) .
32+ :::
33+
34+ ## enable_runfiles
35+
36+ :::{bzl: target } enable_runfiles
37+
38+ Special target for the Bazel-builtin ` //command_line_option:enable_runfiles ` flag.
39+
40+ See the [ Bazel documentation for --enable_runfiles] ( https://bazel.build/reference/command-line-reference#flag--enable_runfiles ) .
41+ :::
Original file line number Diff line number Diff line change @@ -402,16 +402,21 @@ versions of a library] for a more concrete example.
402402
403403:::{important}
404404Labels with package `command_line_option` are handled specially: they are treated
405- as aliases for the Bazel-builtin `//command_line_option:<name>` psuedo-targets.
405+ as the Bazel-builtin `//command_line_option:<name>` psuedo-targets.
406406
407407e.g. `@foo//command_line_option:NAME` will attempt to transition
408408the Bazel-builtin `//command_line_option:NAME` setting.
409409
410410See the {obj}`@rules_python//command_line_option` package for some predefined
411- aliases , or define your own by putting them in your own `command_line_option`
411+ special targets , or define your own by putting them in your own `command_line_option`
412412directory.
413413:::
414414
415+ :::{seealso}
416+ * {obj}`//command_line_option:build_runfile_links`
417+ * {obj}`//command_line_option:enable_runfiles`
418+ :::
419+
415420:::{note}
416421These values are transitioned on, so will affect the analysis graph and the
417422associated memory overhead. The more unique configurations in your overall
You can’t perform that action at this time.
0 commit comments