Skip to content

Commit 334dd44

Browse files
authored
Add gazelle config note (#288)
fixes #284 --- ### Type of change - Documentation (updates to documentation or READMEs) ### Test plan None
1 parent d83ef8b commit 334dd44

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

README.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,3 +47,15 @@ We think you'll love rules_py because:
4747

4848
Follow instructions from the release you wish to use:
4949
<https://github.com/aspect-build/rules_py/releases>
50+
51+
### Using with Gazelle
52+
53+
In any ancestor `BUILD` file of the Python code, add these lines to instruct [Gazelle] to create rules_py variants of the `py_*` rules:
54+
55+
```
56+
# gazelle:map_kind py_library py_library @aspect_rules_py//py:defs.bzl
57+
# gazelle:map_kind py_binary py_binary @aspect_rules_py//py:defs.bzl
58+
# gazelle:map_kind py_test py_test @aspect_rules_py//py:defs.bzl
59+
```
60+
61+
[Gazelle]: https://github.com/bazelbuild/rules_python/blob/main/gazelle/README.md

0 commit comments

Comments
 (0)