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

chore: Disable default golangci-lint exclusions #712

Merged
merged 1 commit into from
Dec 20, 2023

Conversation

killianmuldoon
Copy link
Contributor

@killianmuldoon killianmuldoon commented Dec 19, 2023

Set .issues.exclude-use-default: false to expose new linter findings and fix them.

This will enable checking for package comments and comments on exported types going forward.

@@ -21,6 +21,7 @@ import (
)

const (
// HostDeviceNetworkCRDName is used for the CRD Kind.
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Most of the changes in this PR are adding comments or slightly changing existing comments to meet Go conventions.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Enabling this now and fixing outstanding issues means we'll have a check for comments on packages and exported types in future.

@@ -133,7 +135,7 @@ func main() {
}
// Generate new file full path
outputFile := filepath.Join(*outputDir, strings.Replace(filepath.Base(file), ".template", ".yaml", 1))
f, err := os.Create(outputFile)
f, err := os.Create(filepath.Clean(outputFile))
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's three instances of adding filepath.Clean() to file operations which was caught by the gosec linter.

@killianmuldoon killianmuldoon changed the title Disable default golangci-lint exclusions chore: Disable default golangci-lint exclusions Dec 19, 2023
@rollandf
Copy link
Member

Hey, add a new line to the PR text to make Conventional Commit PR message check / check-for-cc (pull_request) happy

@rollandf
Copy link
Member

Should we hold this to not get conflict with Alex's PRs?

@almaslennikov
Copy link
Collaborator

Hey, after merging #706 the project layout has changed. Could you rebase your PR?

@adrianchiris adrianchiris merged commit 442c744 into Mellanox:master Dec 20, 2023
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants