jish / pre-commit

A slightly improved pre-commit hook for git
https://jish.github.io/pre-commit/
Other
796 stars 96 forks source link

Ignore if there is no rvm in path #189

Closed arashm closed 10 years ago

arashm commented 10 years ago

I use rbenv and not rvm, Every time I use pre-commit it show me an error first:

which: no rvm in ($PATH...)

It does the job but the error is annoying.

mpapis commented 10 years ago

@jish not sure if you want to do release for this?

jish commented 10 years ago

Does installing the manual hook work for you?

pre-commit install --manual

If that doesn't work, you can re-install the default hook using:

pre-commit install

Josh

On Oct 31, 2014, at 08:09, Michal Papis notifications@github.com wrote:

@jish not sure if you want to do release for this?

— Reply to this email directly or view it on GitHub.

mpapis commented 10 years ago

well, haven't played with it in some time, I thought we have tests for it (on conference right now, will test tomorrow)

jish commented 10 years ago

I was just curious if using the simpler manual hook https://github.com/jish/pre-commit/blob/81c95c97bd6f01fe0db5aba24f5eef8df3af210d/templates/hooks/manual would avoid the environment detection problems.

require 'pre-commit'
PreCommit.run
jish commented 10 years ago

@mpapis I released a new version 0.21.0 with your patch.

@arashm thanks for letting us know about this issue! :) If you update the gem the error should go away.

mpapis commented 10 years ago

so finally got reason to use pre-commit => https://github.com/pre-commit-plugins/pre-commit-gpg

also tested the hook installation - it all works well for manual and default installation

jish commented 10 years ago

@mpapis cool! :)