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

Allow to skip pre-commit hooks (some way) #513

Closed
elia opened this issue Feb 4, 2019 · 9 comments

Comments

Projects
None yet
4 participants
@elia
Copy link

commented Feb 4, 2019

I work on a project that's very heavy on pre-commit hooks, and often they need to be skipped. I know the "commit with no-verify" has been removed recently. These are the alternative solutions I that I can see working for me:

  • Add a check near amend to skip verification
  • Add a key modifier that will change the commit button in "commit without verifying"
  • Allow to easily copy the whole commit message (⌘A + ⌘C) so that I can go to the terminal and do git commit -n manually
@DanPristupov

This comment has been minimized.

Copy link
Contributor

commented Feb 6, 2019

I think we will proceed with the the first option. I will introduce an option to skip hooks.

@DanPristupov DanPristupov added this to the 1.0.74 milestone Feb 6, 2019

@DanPristupov

This comment has been minimized.

Copy link
Contributor

commented Feb 15, 2019

Alright, the option to skip pre-commit hooks is back in 1.0.74. After a week I found another approach to make it work. Please check for updates.

@Naatan

This comment has been minimized.

Copy link

commented Feb 28, 2019

Where is this option? Mine seems to always be skipping pre-commit hooks.. :\

@DanPristupov

This comment has been minimized.

Copy link
Contributor

commented Feb 28, 2019

@Naatan The option to skip pre-commit hooks will appear in the error dialog which appears on hook failure.

Actually Fork doesn't run hooks, git does.
Are you sure your hook has executable rights (chmod +x)?
Did it work previously?

@debone

This comment has been minimized.

Copy link

commented Apr 25, 2019

I used to be able to skip this hooks some time ago, but now the pop-up is showing up like this
image
Was there any changes related to it? I'm on version 1.0.77

@DanPristupov

This comment has been minimized.

Copy link
Contributor

commented Apr 25, 2019

@debone Are you sure you have a pre-commit, commit-msg or post-commit hook in .git/hooks?

image

@debone

This comment has been minimized.

Copy link

commented Apr 30, 2019

Hey @DanPristupov, yes, I do have only a pre-commit

~/sources/project/ <master> » cat .git/hooks/pre-commit
#!/bin/sh

npm run lint

And this command fails because reasons, and I'd like to skip it as I'm not looking into fix it

@DanPristupov

This comment has been minimized.

Copy link
Contributor

commented Apr 30, 2019

@debone are you sure your hook fails because of reasons and not because of different ENV? Did you start Fork from CLI? If not, then you probably should.

@debone

This comment has been minimized.

Copy link

commented Apr 30, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.