Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot combine presets and disable #3670

Closed
4 tasks done
ThinkChaos opened this issue Mar 11, 2023 · 2 comments
Closed
4 tasks done

Cannot combine presets and disable #3670

ThinkChaos opened this issue Mar 11, 2023 · 2 comments
Labels
question Further information is requested

Comments

@ThinkChaos
Copy link

Welcome

  • Yes, I'm using a binary release within 2 latest major releases. Only such installations are supported.
  • Yes, I've searched similar issues on GitHub and didn't find any.
  • Yes, I've included all information below (version, config, etc.).
  • Yes, I've tried with the standalone linter if available (e.g., gocritic, go vet, etc.). (https://golangci-lint.run/usage/linters/)

Description of the problem

When using presets, disable doesn't work.

As a workaround, it's possible to use exclude-rules, but that's probably less efficient since I'd guess the linters still run:

issues:
  exclude-rules:
    - path: '.'
      linters:
        - typecheck

Version of golangci-lint

$ golangci-lint --version
golangci-lint has version 1.50.1 built from v1.50.1 on 19700101-00:00:00

Configuration file

$ cat .golangci.yml
linters:
  disable:
    - typecheck

  disable-all: false
  presets:
    - bugs
    - unused

Go environment

Not relevant.

Verbose output of running

Not relevant.

Code example or link to a public repository

Not relevant.
@ThinkChaos ThinkChaos added the bug Something isn't working label Mar 11, 2023
@boring-cyborg
Copy link

boring-cyborg bot commented Mar 11, 2023

Hey, thank you for opening your first Issue ! 🙂 If you would like to contribute we have a guide for contributors.

@bombsimon
Copy link
Member

typecheck is not a real linter and cannot be disabled. Suggestion to improve documentation in #3460

@bombsimon bombsimon added question Further information is requested and removed bug Something isn't working labels Mar 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants