All of lore.kernel.org
 help / color / mirror / Atom feed
From: Wainer dos Santos Moschetta <wainersm@redhat.com>
To: "Alex Bennée" <alex.bennee@linaro.org>, qemu-devel@nongnu.org
Cc: "Willian Rampazzo" <willianr@redhat.com>,
	"Thomas Huth" <thuth@redhat.com>,
	berrange@redhat.com, "Philippe Mathieu-Daudé" <f4bug@amsat.org>
Subject: Re: [RFC PATCH] scripts/checkpatch: roll diff tweaking into checkpatch itself
Date: Tue, 8 Jun 2021 09:52:01 -0300	[thread overview]
Message-ID: <9f79bb3d-2f0d-9a5c-00d8-bcca06cb02c6@redhat.com> (raw)
In-Reply-To: <20210607171829.25111-1-alex.bennee@linaro.org>


On 6/7/21 2:18 PM, Alex Bennée wrote:
> Rather than relying on external tweaks lets just do it inside
> checkpatch's direct commitish handling which is QEMU specific code
> anyway.
>
> Suggested-by: Daniel P. Berrangé <berrange@redhat.com>
> Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
> ---
>   .gitlab-ci.d/static_checks.yml | 3 ---
>   .patchew.yml                   | 3 ---
ah, there is the patchew configuration file.
>   scripts/checkpatch.pl          | 7 ++++++-
>   3 files changed, 6 insertions(+), 7 deletions(-)

Reviewed-by: Wainer dos Santos Moschetta <wainersm@redhat.com>

>
> diff --git a/.gitlab-ci.d/static_checks.yml b/.gitlab-ci.d/static_checks.yml
> index 7e685c6a65..c5fa4fce26 100644
> --- a/.gitlab-ci.d/static_checks.yml
> +++ b/.gitlab-ci.d/static_checks.yml
> @@ -4,9 +4,6 @@ check-patch:
>     needs:
>       job: amd64-centos8-container
>     script:
> -    - git config --local diff.renamelimit 0
> -    - git config --local diff.renames True
> -    - git config --local diff.algorithm histogram
>       - .gitlab-ci.d/check-patch.py
>     variables:
>       GIT_DEPTH: 1000
> diff --git a/.patchew.yml b/.patchew.yml
> index 2638b7f564..1b78262ce5 100644
> --- a/.patchew.yml
> +++ b/.patchew.yml
> @@ -138,9 +138,6 @@ testing:
>         script: |
>           #!/bin/bash
>           git rev-parse base > /dev/null || exit 0
> -        git config --local diff.renamelimit 0
> -        git config --local diff.renames True
> -        git config --local diff.algorithm histogram
>           ./scripts/checkpatch.pl --mailback base..
>       docker-mingw@fedora:
>         enabled: true
> diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
> index bbcd25ae05..cb8eff233e 100755
> --- a/scripts/checkpatch.pl
> +++ b/scripts/checkpatch.pl
> @@ -399,7 +399,12 @@ if ($chk_branch) {
>   	my $num_patches = @patches;
>   	for my $hash (@patches) {
>   		my $FILE;
> -		open($FILE, '-|', "git", "show", "--patch-with-stat", $hash) ||
> +		open($FILE, '-|', "git",
> +                     "-c", "diff.renamelimit=0",
> +                     "-c", "diff.renames=True",
> +                     "-c", "diff.algorithm=histogram",
> +                     "show",
> +                     "--patch-with-stat", $hash) ||
>   			die "$P: git show $hash - $!\n";
>   		while (<$FILE>) {
>   			chomp;



      parent reply	other threads:[~2021-06-08 12:53 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-07 17:18 [RFC PATCH] scripts/checkpatch: roll diff tweaking into checkpatch itself Alex Bennée
2021-06-07 17:29 ` Daniel P. Berrangé
2021-06-07 18:07 ` Willian Rampazzo
2021-06-08  6:35 ` Philippe Mathieu-Daudé
2021-06-08 12:52 ` Wainer dos Santos Moschetta [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=9f79bb3d-2f0d-9a5c-00d8-bcca06cb02c6@redhat.com \
    --to=wainersm@redhat.com \
    --cc=alex.bennee@linaro.org \
    --cc=berrange@redhat.com \
    --cc=f4bug@amsat.org \
    --cc=qemu-devel@nongnu.org \
    --cc=thuth@redhat.com \
    --cc=willianr@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.