Skip to content

Commit 5e0b524

Browse files
authored
Contributing: Clarify width of snippets (#34910)
Clarifies the width rules for snippets.
1 parent 64a0442 commit 5e0b524

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

CONTRIBUTING.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,9 @@ Please follow these formatting guidelines:
159159

160160
* Java indent is 4 spaces
161161
* Line width is 140 characters
162-
* Line width for code snippets that are included in the documentation (the ones surrounded by `// tag` and `// end` comments) is 76 characters
162+
* Lines of code surrounded by `// tag` and `// end` comments are included in the
163+
documentation and should only be 76 characters wide not counting
164+
leading indentation
163165
* The rest is left to Java coding standards
164166
* Disable “auto-format on save” to prevent unnecessary format changes. This makes reviews much harder as it generates unnecessary formatting changes. If your IDE supports formatting only modified chunks that is fine to do.
165167
* Wildcard imports (`import foo.bar.baz.*`) are forbidden and will cause the build to fail. This can be done automatically by your IDE:

0 commit comments

Comments
 (0)