Re: [PATCH] ci: github action - add check for whitespace errors
- From
Chris Webster <chris@webstech.net>
- Date
- Sep 22, 2020, 22:41 UTC
- Message-ID
- <CAGT1KpU4Kjv2PEAA7-bNbGp2DFvfsKqABuUK68128xkLjdcEhA@mail.gmail.com>
- In-Reply-To
- <xmqq1ritlmrk.fsf@gitster.c.googlers.com>
On Tue, Sep 22, 2020 at 10:55 AM Junio C Hamano <gitster@pobox.com> wrote:
Show 13 quoted lines
> > Jeff King <peff@peff.net> writes: > > > - this will run only on PRs. That's helpful for people using > > GitGitGadget, but it might also be useful for people just running the > > CI by pushing branches, or looking at CI builds of Junio's next or > > seen branches. Could we make it work there? Obviously we wouldn't be > > able to rely on having PR data, but I wonder if "git log > > HEAD..$branch" would be sufficient. > > Yes, I like that very much. If a push triggers a CI run to notice > whitespace breakage and other mechanically detectable errors, that > would prevent embarrassment before even a pull request is opened.
This was originally started as a push action which was expected to be in the GitGitGadget workflow. It was changed to run on PRs using the more helpful PR data. The original GitGitGadget issue suggested a build target to run the check, which could have been part of the CI build (or a local build). Doing the check later as part of the PR process is consistent with GitGitGadget performing linting on the PR request, with similar opportunities for embarrassment.
...chris.