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

Do not require installing file2byteslice to update go generate'd files. #2221

Merged
merged 1 commit into from
Jul 29, 2022

Conversation

divVerent
Copy link
Contributor

The tool is already referenced in go.mod, so it is trivial to just go run it - that way, go generate can use it without the user explicitly installing it first.

Tested: modifying gobind.go and running go generate now applies correctly to gobind.src.go.

Note that this means that GOOS=windows go generate no longer will work on Linux - if this is a problem, we could prepend the go command with env GOOS= GOARCH= every time. This same limitation also already exists for some of your go run commands in there, though, so I thought it's fine to keep it that way.

Copy link
Owner

@hajimehoshi hajimehoshi left a comment

Choose a reason for hiding this comment

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

LGTM, thanks!

@hajimehoshi hajimehoshi merged commit 21207f8 into hajimehoshi:main Jul 29, 2022
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.

2 participants