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

feat: capitalise var naming to IDs #964

Merged

Conversation

VincentBaron
Copy link
Contributor

var-naming does not check that ID is capitalised when it is plural such as IDs. For example if I have uIds := []string{} it will allow this var name where really it should return var uIds should be uIDs.

Closes #947

@chavacava
Copy link
Collaborator

Hi @VincentBaron, thanks for the PR!
Could you please add some test cases.

.gitignore Outdated Show resolved Hide resolved
@VincentBaron
Copy link
Contributor Author

I added a test for this case :)

@denisvmedia denisvmedia merged commit 64dda06 into mgechev:master Jan 17, 2024
4 checks passed
@VincentBaron
Copy link
Contributor Author

@denisvmedia do you know when you are planning the next tag? As I am using revive via golangci-lint I will need to do a PR to them to update to your latest version :)

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.

var-naming rule to check that plural vars with ID are capitalised
3 participants