From patchwork Wed May 1 13:53:05 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masahiro Yamada X-Patchwork-Id: 163211 Delivered-To: patch@linaro.org Received: by 2002:a92:7e86:0:0:0:0:0 with SMTP id q6csp4549529ill; Wed, 1 May 2019 06:53:41 -0700 (PDT) X-Google-Smtp-Source: APXvYqwyRb/jzqmjMS/ROHcwxuqCqUtusJ7HdSMzFKoXTPmk/2d3XsEvmR7557CsKySI5Fl2U0de X-Received: by 2002:a17:902:a402:: with SMTP id p2mr1842714plq.131.1556718821770; Wed, 01 May 2019 06:53:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1556718821; cv=none; d=google.com; s=arc-20160816; b=VJaq11LjE5Pt/I98SLxSiPfVIocPzqLrWlqLGQr6wKsV5kLXiiTCswJwVvP8A4/27K g8Y16qd61ootsg6hamn6qx/Bj9RK3MtKbtKwOAMcjI9l2WC94kj681eQM3fcu2h8bNRT EPjAiaah14f1fPpmglur4Y579LF0gguBOSZVdboNxQfbnx3a3kMSs2ZXTnMV1spMeLYp /E7iYguMUMo8bfZDXWksYpcOoMMDgvKKi/MEG/v6HlxeIL3tpikpuzM/a14Jsc1ggx6Y fPb5KUVhKrGfVXxyPnwdMumaxphDJpdqxytiIb8mJanQCPb2jj0FqdKDye4fkR+Kjzlw x1hA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature:dkim-filter; bh=f6uJF7746NTCDxjp6+FkBz2Du0qsSubKTcds7GgCmco=; b=BokadZk2k7gjn/6B8G2HBzfoPYddcU2HlUeo/QvndYtyzfnIyJ0VCL0DnYMsTCcM6S 9q8Eo857oUGtEHvvKThO+GNgInHNdaGC8sm2uVVlmU6r4gAkLwb+JvfEZuvPSTZw2LgL W0sdG/9i1kkzdIdf6sth/paKv10df0IyjLRg7Bt9PCn3DE74gMmabf7xUL2X9oCsP1Tz z891SS9x02+oKnhnz5T9GTfP6llSst6QFJ190+xYmD0OmjUPQnABOhVQHHXLm8b4nc9H AS5JaEGWH0rWNMcZNv3L5eWYDC1U/oJj7UQwmjCtNdHTDnNYtoBG955+P6Gau9FsntJT 748Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=SJA5DhTT; spf=pass (google.com: best guess record for domain of linux-acpi-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-acpi-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r203si7525934pfr.77.2019.05.01.06.53.41; Wed, 01 May 2019 06:53:41 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-acpi-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=SJA5DhTT; spf=pass (google.com: best guess record for domain of linux-acpi-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-acpi-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726423AbfEANxl (ORCPT + 9 others); Wed, 1 May 2019 09:53:41 -0400 Received: from conuserg-07.nifty.com ([210.131.2.74]:65220 "EHLO conuserg-07.nifty.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726478AbfEANxl (ORCPT ); Wed, 1 May 2019 09:53:41 -0400 X-Greylist: delayed 169645 seconds by postgrey-1.27 at vger.kernel.org; Wed, 01 May 2019 09:53:39 EDT Received: from grover.flets-west.jp (softbank126125154137.bbtec.net [126.125.154.137]) (authenticated) by conuserg-07.nifty.com with ESMTP id x41Dr9KW001783; Wed, 1 May 2019 22:53:09 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conuserg-07.nifty.com x41Dr9KW001783 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1556718790; bh=f6uJF7746NTCDxjp6+FkBz2Du0qsSubKTcds7GgCmco=; h=From:To:Cc:Subject:Date:From; b=SJA5DhTTi821Pj+Q5LYIHqGxGy2XM2r0Ng2p26UQO6PkIgt+5rBBRp0Cyhe1KOTYw nwONMzvbm9uYd0isyedRBSvziHXPGi4B/E35xIPVpGe4uRXCFeIrPDFT5HQosLhJSp zRT/GT7NzuED8Uq7Qjurvb2F1CH4AIhVjKOqKkIbTKiu2lcOLeCrZByp16SN0rUAvV BjwCX3YH7R76EGw58UrGw81RFCjob7ELLodCd6qsTQYWvhKS9gAs/OU30h8YsMO2Y+ kh3RqFXH2jdbHCKPM41ZMrt/OMy8OUCUDBNWRf/izouPRkjOJLs6IlEn6ml2iyIPNj uFGhca07xFLcg== X-Nifty-SrcIP: [126.125.154.137] From: Masahiro Yamada To: "Rafael J . Wysocki" , linux-acpi@vger.kernel.org Cc: Masahiro Yamada , "Rafael J. Wysocki" , Robert Moore , linux-kernel@vger.kernel.org, Len Brown , Erik Schmauss , devel@acpica.org Subject: [PATCH v2] tools/power/acpi: exclude tools/* from .gitignore pattern Date: Wed, 1 May 2019 22:53:05 +0900 Message-Id: <1556718785-4417-1-git-send-email-yamada.masahiro@socionext.com> X-Mailer: git-send-email 2.7.4 Sender: linux-acpi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org tools/power/acpi/.gitignore has the following entries: acpidbg acpidump ec They are intended to ignore the following build artifacts: tools/power/acpi/acpidbg tools/power/acpi/acpidump tools/power/acpi/ec However, those .gitignore entries are effective not only for the current directory, but also for any sub-directories. So, from the point of .gitignore grammar, the following check-in directories are also considered to be ignored: tools/power/acpi/tools/acpidbg tools/power/acpi/tools/acpidump tools/power/acpi/tools/ec As the manual gitignore(5) says "Files already tracked by Git are not affected", this is not a problem as far as Git is concerned. However, Git is not the only program that parses .gitignore because .gitignore is useful to distinguish build artifacts from source files. For example, tar(1) supports the --exclude-vcs-ignore option. As of writing, this option does not work perfectly, but it intends to create a tarball excluding files specified by .gitignore. So, I believe it is better to fix this issue. You can fix it by prefixing the pattern with a slash; the leading slash means the specified pattern is relative to the current directory. I also prefixed the "include" consistently. IMHO, it is safer when you intend to ignore specific files or directories. Signed-off-by: Masahiro Yamada --- Changes in v2: - Add more information to the commit log to clarify my main motivation tools/power/acpi/.gitignore | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) -- 2.7.4 diff --git a/tools/power/acpi/.gitignore b/tools/power/acpi/.gitignore index cba3d99..f698a0e 100644 --- a/tools/power/acpi/.gitignore +++ b/tools/power/acpi/.gitignore @@ -1,4 +1,4 @@ -acpidbg -acpidump -ec -include +/acpidbg +/acpidump +/ec +/include/