Skip to content

Commit 374b3fd

Browse files
authored
docs: add forbidigo example that uses comments (#2599)
1 parent 0831dac commit 374b3fd

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

.golangci.example.yml

+3
Original file line numberDiff line numberDiff line change
@@ -280,6 +280,9 @@ linters-settings:
280280
forbid:
281281
- ^print.*$
282282
- 'fmt\.Print.*'
283+
# Optionally put comments at the end of the regex, surrounded by `(# )?`
284+
# Escape any special characters.
285+
- 'fmt\.Print.*(# Do not commit print statements\.)?'
283286
# Exclude godoc examples from forbidigo checks.
284287
# Default: true
285288
exclude_godoc_examples: false

0 commit comments

Comments
 (0)