Quick wins for a faster PC:
Repair Windows errors before they cause bigger problemsFix Now →Scan for outdated or missing drivers - takes under a minuteDriver Scan →Clear out junk files and repair common Windows errorsFree Scan →For standalone godoclint, configure rule selection and per-rule options in .godoc-lint.yaml (the README also accepts .godoclint.yaml). Use a source directive for a narrow exception, a top-level directive to disable checks across one file, or an exclude path pattern when a generated or legacy file should not be edited. If godoc-lint runs through golangci-lint, use golangci-lint’s configuration instead: the two configuration schemas differ.
Choose standalone godoc-lint or golangci-lint first
Identify which runner checks your Go code before changing configuration. Standalone godoc-lint reads its own YAML settings. When integrated with golangci-lint, its settings and exclusions belong to golangci-lint’s configuration; standalone keys should not be copied over as if the formats were interchangeable.
Run standalone godoc-lint
From the repository root, run godoclint ./... to check all Go packages. To narrow the target, use a package path such as godoclint ./internal/foo/bar or a subtree such as godoclint ./internal/....
By default, the tool looks for .godoc-lint.yaml in its working directory; the project README also accepts .godoclint.yaml. To choose another file, pass -config, for example godoclint -config the-config-file.yaml ./....
#1 Best Overall
Configuration can be placed in subdirectories. For each processed package, godoc-lint uses a config in that package’s directory if present; otherwise it walks up parent directories toward the root where the linter was invoked. This allows a package or subtree to use a local configuration.
Configure the golangci-lint integration
The godoc-lint project says integration is available in golangci-lint v2.5.0 and later. Its README gives this enablement example:
version: "2"
linters:
enable:
- godoclint
This enables the linter; it is not a standalone godoc-lint configuration. Consult the current golangci-lint settings for integrated rule configuration and exclusions. The project README specifically points users toward golangci-lint’s linters.exclusions.rules for excluding test files when appropriate.
Select standalone rules
In standalone configuration, default sets the starting rule set: basic, all, or none. Without an overriding config, the documented default is basic. The basic set enables pkg-doc, single-pkg-doc, start-with-name, and deprecated. Choose all to activate every rule, or none to build a deliberate allowlist with enable. Add or remove rules with the enable and disable lists.
Crashes, No Sound, or Screen Glitches?
Random freezes, missing sound and display glitches usually trace back to one bad driver. Find and replace yours safely.Free scan · under a minutePC Slower Than It Used to Be?
A free scan shows the junk files, broken settings and background clutter dragging Windows down - then fixes them in one click.Free scan · Windows 10 & 11The other documented rules cover these checks:
require-docrequires comments for exported symbols and, when configured, unexported symbols.require-pkg-docrequires package documentation.max-lenlimits rendered godoc line length. Its standalone default is 77 characters, excluding the//,/*, and*/delimiter tokens.no-unused-linkdetects unused documentation links.require-stdlib-doclinksuggests documentation links for standard-library identifiers mentioned as plain text.
Rule-specific settings belong under options. This illustrative standalone configuration combines documented keys; it is not represented as a configuration validated by running the linter:
version: "1.0"
default: basic
enable:
- require-doc
- max-len
disable:
- deprecated
options:
max-len/length: 88
max-len/ignore-patterns:
- "^TODO:"
require-doc/include-tests: false
In the upstream default configuration, max-len/length is 77 and max-len/ignore-patterns is an empty list. Documented include-tests options default to false. Other documented defaults include start-with-name/include-unexported: false, require-doc/ignore-unexported: true, and require-doc/ignore-exported: false.
Ignore a warning at the narrowest useful scope
One declaration and selected rules
Put the directive in the declaration’s documentation comment group. The syntax requires no space between the comment slashes and the directive:
// This is a constant.
//
godoclint:disable start-with-name
const Foo = 0
Use //godoclint:disable start-with-name in place of the directive line shown above; the required syntax begins with // immediately followed by godoclint:disable. List multiple rule names separated by spaces to suppress several checks for that declaration. If the directive has no rule names, it disables all rules for the declaration’s godoc. Multiple directives are also supported.
The Tool Desk
Outbyte Driver Updater FREEScan for outdated or missing drivers - takes under a minuteDriver Scan →Outbyte PC Repair FREEClear out junk files and repair common Windows errorsFree Scan →Every declaration in one file
To turn off all rules for a file, place //godoclint:disable in a top-level, non-godoc comment group. The project README’s example places it after the package line. This is broader than an exception attached to one declaration.
Rank #4
Generated or legacy paths
When a file should not be edited to add a source directive, use standalone exclude patterns. Standalone include and exclude values are regular expressions matched against paths relative to the configuration file. Use forward slashes in path patterns on every platform, including Windows:
exclude:
- ^internal/generated/
- _autogenerated.go$
The upstream default config has include: null and exclude: null, so it applies no explicit path filter. For golangci-lint, configure per-file exclusions in golangci-lint’s own settings instead.
Decide how test files are checked
Most listed standalone rule options skip _test.go files by default. To check tests for a particular rule, set that rule’s .../include-tests: true option. This is configured per rule, so enabling a rule alone does not necessarily make it inspect test files. Alternatively, golangci-lint users may use its path-based exclusions to omit test files.
Recommended Free Tools
Best Value
Standalone pkg-doc automatically exempts command packages named main and their test packages named main_test by default.
Use standalone CLI overrides when appropriate
Standalone command-line options can override rule selection and path filters for a run:
-defaultacceptsbasic,all, ornone.- Repeat
-enableor-disableto select rules. - Repeat
-includeor-excludeto supply regular-expression path filters.
As with YAML path patterns, CLI path patterns should use forward slashes even on Windows.
Match the exception to the problem
- One declaration triggers one unwanted rule: add a named
//godoclint:disabledirective to its documentation comment. - A whole file must be exempt: use the top-level non-godoc directive.
- A generated or legacy file should remain untouched: use a standalone
excluderegex, or the corresponding golangci-lint exclusion if that is the runner. - Only some rules should inspect tests: set each relevant standalone rule’s
include-testsoption; do not assume rule enablement includes tests. - The desired check is missing or overly strict: adjust standalone
default,enable,disable, or the relevantoptionsvalue rather than broadly disabling the file.
The project README and default YAML are on the moving upstream main branch, so configuration can change. The README’s standalone install examples showed v0.11.3 when accessed for this article; check the version installed in your environment if a key or behavior differs. The stated golangci-lint integration milestone is v2.5.0.
Do these 3 things before closing this tab:
1Clear out junk files and repair common Windows errors2Fix the driver behind crashes, sound loss and screen glitches3Repair Windows errors before they cause bigger problemsQuick Recap
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

