golint

golint lints the Go source files named on its command line.

Version

cb00e5669539f047b2f4c53a421a01b0c8e172c6

Runtime

Go Versions

Supported Languages

Go

Official Documentation

https://godoc.org/github.com/golang/lint/golint

YAML Configuration

golint:

  • input:

    Patterns to include in execution and reports.

  • ignore:

    Patterns to exclude from execution and reports.

  • auto-fix:

    true/false

    Note: As of now, golint does not keep CRLF line endings and all EOL characters are converted to LF in files where the auto-fix is applied. We will solve this problem, but for the time being, please don't enable the auto-fix feature if you need to keep CRLF line endings.

  • config-file:

    N/A

  • machine:

    • cpu:

      Amount of CPU. The default machine has 0.75 CPU with 2880 MiB RAM.

  • options:

    Below is the list of options that are supported:

    -min_confidence float
          minimum confidence of a problem to print it (default 0.8)
    

YAML Examples

  • With default options:

    inspecode:
      golint: default
    
  • With enabling auto-fixing and default options:

    inspecode:
      golint: auto-fix
    
  • With custom machine:

    inspecode:
      golint:
        machine:
          cpu: 1.5 # 1.5 CPU, 5760 MiB RAM
    
  • With custom options:

    inspecode:
      golint:
        options:
          -min_confidence: 1.0
    

Resolving Dependencies

Inspecode may require the build dependencies when fixing golint issues automatically (auto-fix: true), so Inspecode resolves the dependencies in the same manner as go test. See the go test page for the details.

results matching ""

    No results matching ""