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

Integration as a pre-commit hook #19

Closed
Lucas-C opened this issue Jan 30, 2017 · 1 comment
Closed

Integration as a pre-commit hook #19

Lucas-C opened this issue Jan 30, 2017 · 1 comment

Comments

@Lucas-C
Copy link

Lucas-C commented Jan 30, 2017

Hi.

Some devs at Yelp have written a CLI tool to register & run git pre-commit hooks easily : http://pre-commit.com

I've contributed a few hooks myself in Python, and they just added support for Go hooks: pre-commit/pre-commit#430

Hence I tried to add a checkmake-based hook : https://github.com/Lucas-C/pre-commit-hooks-go

However the fact that it requires a make invocation to build makes it "non standard".
At the moment, pre-commit only support go get ./... + the installation of additional dependencies: https://github.com/pre-commit/pre-commit/blob/master/pre_commit/languages/golang.py#L67

Do you think it would be possible to make some changes to the build process of checkmake in order to integrate it as a pre-commit hook ?

There are 2 options I think:

  • the simplest : make it installable with a simple go get ./...
  • use a common tool instead. I don't know much about the Go ecosystem : maybe gb or gom ? And then we would check with the pre-commit dev team if they are OK to support it.
@mrtazz mrtazz closed this as completed in 2d3fb76 Jul 28, 2017
@mrtazz
Copy link
Owner

mrtazz commented Jul 28, 2017

This should work now with the caveat mentioned in 2d3fb76

@trinitronx trinitronx mentioned this issue Apr 27, 2022
5 tasks
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