Is there a way to disable the commit Message Hook ?
What would you like to be able to do?
Hello, I'm exploring the integration of this plugin inside one of my projects, and for now, I only want to use a pre commit hook, that part is working, but my commits are rejected because of the commit message hook :)
Is there a way to disable the creation of this hook ?
PS: nice work !
If you have any ideas on how this should be implemented, please tell us here.
Naively I would use something like this
commitMsg {
disabled = true
}
Is this a feature you are interested in implementing yourself?
Yes
I tried commitMsg {}, that created an empty file .git\hooks\commit-msg but the commit failed with "error: cannot spawn .git/hooks/commit-msg: No such file or directory" as if the empty file was not set with +x right
Hi, I tried to reproduce this issue, and I was not able to. Can you provide a minimal reproduction example?
I will be on holiday next week, I can try to do so then.
Consider the following options:
- If you do not want a commit-msg, just omit that configuration block
- although
commitMsg { }seems to work on Linux and OSX, it seems to be not to on Windows (sic). Try alsocommitMsg { from("#!/bin/sh") { "true" } }