From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id BAFC4C388F9 for ; Fri, 23 Oct 2020 01:07:59 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 4D54421D43 for ; Fri, 23 Oct 2020 01:07:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1603415279; bh=QUPe+Z5yuuDxRxrVWu6L0bgSs18iMo70fZAuMuQMxms=; h=Date:From:To:Subject:Reply-To:List-ID:From; b=ES+/DMU1B9NVUxIFVZHaW5Vgq72KNTzuTlB2VE/mV9gHgIeZYzADMhfanzNmfEEVu seloZsAHcvjqFUuXA914cUvdDRSVl1vb1Oe3+gWNe0VyUYoPSv1ofLxkQXLYXP4M+P xZZ4lsA3RuuSvD5vJNqN5t+0dScYGfibiC9DxGdo= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S368914AbgJWBH6 (ORCPT ); Thu, 22 Oct 2020 21:07:58 -0400 Received: from mail.kernel.org ([198.145.29.99]:42636 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2901422AbgJWBH6 (ORCPT ); Thu, 22 Oct 2020 21:07:58 -0400 Received: from X1 (216-169-68-50.scinternet.net [216.169.68.50]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id CAC4920760; Fri, 23 Oct 2020 01:07:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1603415277; bh=QUPe+Z5yuuDxRxrVWu6L0bgSs18iMo70fZAuMuQMxms=; h=Date:From:To:Subject:From; b=a5N61JK+74JZpKegQ0rUukm3xFa1HqfJPBiL44wPt/tT9GofgPAj+92JpW+ZPaY97 S0esFYS7LMYbqjfqLZx3apKFJEUJqHNbDHJgmfn6tFA1OItAfVJSRsRphHtI8XLWMT sxiY0cKjjtDHv6zb9lF1tiQ/nrC44+PIBxAo064M= Date: Thu, 22 Oct 2020 18:07:45 -0700 From: akpm@linux-foundation.org To: mm-commits@vger.kernel.org, joe@perches.com Subject: [to-be-updated] checkpatch-enable-git_dir-environment-use-to-set-git-repository-location.patch removed from -mm tree Message-ID: <20201023010745.8o6qn%akpm@linux-foundation.org> User-Agent: s-nail v14.9.10 Precedence: bulk Reply-To: linux-kernel@vger.kernel.org List-ID: X-Mailing-List: mm-commits@vger.kernel.org The patch titled Subject: checkpatch: enable GIT_DIR environment use to set git repository location has been removed from the -mm tree. Its filename was checkpatch-enable-git_dir-environment-use-to-set-git-repository-location.patch This patch was dropped because an updated version will be merged ------------------------------------------------------ From: Joe Perches Subject: checkpatch: enable GIT_DIR environment use to set git repository location If set, use the environment variable GIT_DIR to change the default .git location of the kernel git tree. If GIT_DIR is unset, keep using the current ".git" default. Link: https://lkml.kernel.org/r/95f9ca20c9c7efe5d40d38e2dd60487e66df43f2.camel@perches.com Signed-off-by: Joe Perches Signed-off-by: Andrew Morton --- scripts/checkpatch.pl | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) --- a/scripts/checkpatch.pl~checkpatch-enable-git_dir-environment-use-to-set-git-repository-location +++ a/scripts/checkpatch.pl @@ -43,6 +43,8 @@ my $list_types = 0; my $fix = 0; my $fix_inplace = 0; my $root; +my $gitroot = $ENV{'GIT_DIR'}; +$gitroot = ".git" if !defined($gitroot); my %debug; my %camelcase = (); my %use_type = (); @@ -908,7 +910,7 @@ sub is_maintained_obsolete { sub is_SPDX_License_valid { my ($license) = @_; - return 1 if (!$tree || which("python") eq "" || !(-e "$root/scripts/spdxcheck.py") || !(-e "$root/.git")); + return 1 if (!$tree || which("python") eq "" || !(-e "$root/scripts/spdxcheck.py") || !(-e "$gitroot")); my $root_path = abs_path($root); my $status = `cd "$root_path"; echo "$license" | python scripts/spdxcheck.py -`; @@ -926,7 +928,7 @@ sub seed_camelcase_includes { $camelcase_seeded = 1; - if (-e ".git") { + if (-e "$gitroot") { my $git_last_include_commit = `${git_command} log --no-merges --pretty=format:"%h%n" -1 -- include`; chomp $git_last_include_commit; $camelcase_cache = ".checkpatch-camelcase.git.$git_last_include_commit"; @@ -954,7 +956,7 @@ sub seed_camelcase_includes { return; } - if (-e ".git") { + if (-e "$gitroot") { $files = `${git_command} ls-files "include/*.h"`; @include_files = split('\n', $files); } @@ -987,7 +989,7 @@ sub git_is_single_file { sub git_commit_info { my ($commit, $id, $desc) = @_; - return ($id, $desc) if ((which("git") eq "") || !(-e ".git")); + return ($id, $desc) if ((which("git") eq "") || !(-e "$gitroot")); my $output = `${git_command} log --no-color --format='%H %s' -1 $commit 2>&1`; $output =~ s/^\s*//gm; @@ -1026,7 +1028,7 @@ my $fixlinenr = -1; # If input is git commits, extract all commits from the commit expressions. # For example, HEAD-3 means we need check 'HEAD, HEAD~1, HEAD~2'. -die "$P: No git repository found\n" if ($git && !-e ".git"); +die "$P: No git repository found\n" if ($git && !-e "$gitroot"); if ($git) { my @commits = (); _ Patches currently in -mm which might be from joe@perches.com are checkpatch-test-git_dir-changes.patch