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

robot should not format vendored code #3

Open
rhysh opened this issue Jun 18, 2018 · 1 comment
Open

robot should not format vendored code #3

rhysh opened this issue Jun 18, 2018 · 1 comment

Comments

@rhysh
Copy link

rhysh commented Jun 18, 2018

Hello, I'm coming here from twitchtv/twirp#114

That pull request changes two lines in code that was vendored by retool to the "_tools" directory.

Our copy of that code is not the right one to change. It should be changed upstream if at all. The robot doesn't need to know about retool, but should know to ignore directories that don't match go doc packages' "..." pattern.

It sounds like @whilei has fixed this already.

@whilei
Copy link
Member

whilei commented Jun 18, 2018

Just noting for reference:

// isGenerated reports whether the source file is generated code
// according the rules from https://golang.org/s/generatedcode.

https://github.com/golang/lint/blob/85993ffd0a6cd043291f3f63d45d656d97b165bd/lint.go#L123-L134
Found here https://blog.mgechev.com/2018/05/28/revive-golang-golint-linter/

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

No branches or pull requests

2 participants