[PATCH for comments] configure: install a whitespace checking pre-commit hook for developers
swen at vnet.ibm.com
Tue Apr 10 11:43:02 UTC 2018
On Tue, 2018-04-10 at 21:32 +1000, Martin Schwenke via samba-technical
> On Tue, 10 Apr 2018 11:58:18 +0200, Stefan Metzmacher via
> samba-technical <samba-technical at lists.samba.org> wrote:
> > The logic for using a script that is part of the checkout and
> > having a
> > .git/hook/pre-commit script that just calls into the working tree
> > is what I'd like to have (and maybe the logic to detect an outdated
> > script)
> I think this is a good approach. This allows us to refine the tool
> even a choice/combination of tools. There is a question about how to
> this neatly...
> The "git commit --no-verify" option to avoid the pre-commit hook can
> even be easily done when committing using magit under Emacs (and
> also with the git support for vim).
> Hmmm... that said, Douglas' pre-commit hook doesn't work under magit.
> It works if I don't specify any paths. For some reason it doesn't
> trigger if I do add the paths that match C and/or Python files. I
> think there's some subtlety in the way the paths are specified in the
> environment magit is running git in. :-(
I don''t know anything about magit but I think the "--cached" parameter
is missed in Douglas' git command line.
Otherwise all changed files will be "checked" while one would only want
the "added" files to be verified.
But I'm afraid that won't help to solve your issue.
More information about the samba-technical