-
Notifications
You must be signed in to change notification settings - Fork 820
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
Add gometalinter to build #163
Comments
Just to add more details - |
@enocom Have you started working on this? If not I’d like to help. |
@EricFortin Go for it. I still haven't picked it up. I'll take my name off it. |
@markmandel @enocom I have started looking into this and would like your input on how to implement this. As it is, the master version of gometalinter is installed in the build image. The build could break anytime even if Agones' code is totally fine. We also run all default linters. When gometalinter adds a new one, it could also break the build for reasons unrelated to the current change being built. In the doc, they recommend using a tagged version and specifying the linters you want to run. This is just a way to shield ourselves a little bit. WDYT? I also saw that some linter default to warning for problem they find which means they aren't outputted and the build wouldn't fail. The most important one I think is the |
I'm not seeing any issues here - if nothing else, also happy for a build to simply fail if any linter fails. gometalinter will let you put in a comment to ignore a specific line if you feel it's a false positive - so we can work around anything we specifically disagree with (unless it's generated code, as we talk about above, and we can @enocom any extra thoughts on your end? |
Making the build fail on |
I already have some |
Hi again, I worked on this a little more and would like your opinion on some topics. As an aside, I discovered that the As for skipping the generated file, there is currently no way to skip a file based on its content. There is an issue opened on it but not much work done though.
|
Here is an example of my config file at the moment:
If I generated it, all filenames would be in the exclude list. |
The config file seems reasonable, although I wonder if adding a |
You would add it after we generate the file? |
Yeah, as a minor and one time annoyance. The risk is subsequent file generations delete the line. But by all means, since you're seeing how painful each option is, let's go with what seems best to you. |
We add licence headers to all generated files - but they all use different methods. Making sure it hits just before the Doing a grep for "autogenerated" and excluding those files is probably the best bet. |
Good I’ll do the grep then. Thank you! |
No description provided.
The text was updated successfully, but these errors were encountered: