[Buildroot] [git commit] lighttpd: adjust Config.in to make check-package happy

Peter Korsgaard peter at korsgaard.com
Wed Oct 31 11:05:17 UTC 2018


>>>>> "Peter" == Peter Korsgaard <peter at korsgaard.com> writes:

>>>>> "Thomas" == Thomas Petazzoni <thomas.petazzoni at bootlin.com> writes:
 >> Hello,
 >> On Wed, 31 Oct 2018 11:21:09 +0100, Peter Korsgaard wrote:

 >>> Ups, wonder how that happened. I'll have a look at executing
 >>> check-package in a git pre-commit hook.

 >> If you do this, could you share whatever you have done? I'd like to
 >> have this here as well, to avoid having such issues in the future.

 > I simply added a post-commit / post-applypatch script which runs 'make
 > checkpackage' for now.

 > A more optimal solution could be made which would only run it on
 > added/changed files, but I haven't tried that. Probably it can be done
 > with git show | lsdiff -s and then filter out removed (prefixed with -)
 > files.

I couldn't help doing it after all. Stick something like this into
.git/hooks/post-commit + .git/hooks/post-applypatch:

# check-package on added/changed files
git show HEAD | \
        lsdiff -s | \
        awk '{ if ($1 != "-") print substr($2, 3) }' | \
        xargs -r ./utils/check-package

-- 
Bye, Peter Korsgaard


More information about the buildroot mailing list