Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

"Ignore post-commit hooks" Jenkins job configuration setting not working with GitLab Hook Plugin #20

Closed
iKiKi opened this Issue Feb 19, 2014 · 3 comments

Comments

Projects
None yet
2 participants

iKiKi commented Feb 19, 2014

The following job configuration setting in a job has no effect. Build are still triggered by the hooks (even with the "Ignore post-commit hooks" checkbox enabled).
jenkins

Sometimes, you need to configure multiple jobs on a same Git repository managed by GitLab. Some jobs need to be triggered by the GitLab Hook Plugin, fine... But other jobs only need to be launched by other triggered.

I tried with build_now and notify_commit, with the same result: "Ignore post-commit hooks" has no effect.

Is that possible to make the Jenkins GitLab Hook Plugin compatible with this Jenkins "Ignore Hook" fetaure ?

I use:

  • Jenkins latest version (1.551)
  • GitLab 6.1.0 b595503
  • Gitlab Hook Plugin 1.0.0
Owner

elvanja commented Feb 24, 2014

Hi @iKiKi, apologies for a late response.

The behavior you propose is already present in the plugin.
You just have to use the ignore notify commit on Git section of your project's configuration, like this:
ignore_notify_commit

If you check the code of this plugin, this line is the key. A project is taken into account for build or notify commit actions only if it doesn't ignore notify commits.

Is that what you wanted?

@elvanja elvanja added the question label Feb 24, 2014

iKiKi commented Feb 25, 2014

That's great, this is exactly what I wanted.
Thanks for your plugin and sorry to have bothered you with my question.
Don't hesitate to add it in your documentation (README.md).

@iKiKi iKiKi closed this Feb 25, 2014

Owner

elvanja commented Feb 25, 2014

Cool, glad to have helped :-)
P.S. The documentation states for notify commit hook that "the project must be configured not to skip notifyCommit", but it's not also explained for build now hook. Thanks for the tip!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment