From: Jens Lehmann <Jens.Lehmann@web.de>
To: Junio C Hamano <gitster@pobox.com>
Cc: Johannes Schindelin <Johannes.Schindelin@gmx.de>, git@vger.kernel.org
Subject: [PATCH 1/2] checkout: Add test for diff.ignoreSubmodules
Date: Sat, 28 Aug 2010 16:49:25 +0200 [thread overview]
Message-ID: <4C7921F5.1050701@web.de> (raw)
In-Reply-To: <4C7921BD.7030600@web.de>
While at it, document that checkout uses this flag too in the Documentation.
Signed-off-by: Jens Lehmann <Jens.Lehmann@web.de>
---
Documentation/config.txt | 3 ++-
t/t2013-checkout-submodule.sh | 7 +++++++
2 files changed, 9 insertions(+), 1 deletions(-)
diff --git a/Documentation/config.txt b/Documentation/config.txt
index 0510ac7..cda6721 100644
--- a/Documentation/config.txt
+++ b/Documentation/config.txt
@@ -829,7 +829,8 @@ diff.renames::
diff.ignoreSubmodules::
Sets the default value of --ignore-submodules. Note that this
affects only 'git diff' Porcelain, and not lower level 'diff'
- commands such as 'git diff-files'.
+ commands such as 'git diff-files'. 'git checkout' also honors
+ this setting when reporting uncommitted changes.
diff.suppressBlankEmpty::
A boolean to inhibit the standard behavior of printing a space
diff --git a/t/t2013-checkout-submodule.sh b/t/t2013-checkout-submodule.sh
index fda3f0a..3beb0b3 100755
--- a/t/t2013-checkout-submodule.sh
+++ b/t/t2013-checkout-submodule.sh
@@ -39,4 +39,11 @@ test_expect_success '"checkout <submodule>" updates the index only' '
git diff-files --quiet
'
+test_expect_success '"checkout <submodule>" honors diff.ignoreSubmodules' '
+ git config diff.ignoreSubmodules dirty &&
+ echo x> submodule/untracked &&
+ git checkout HEAD >actual 2>&1 &&
+ ! test -s actual
+'
+
test_done
--
1.7.2.2.515.g13860
next prev parent reply other threads:[~2010-08-28 14:49 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-08-25 10:34 [PATCH] checkout: respect diff.ignoreSubmodules setting Johannes Schindelin
2010-08-25 17:48 ` Jens Lehmann
2010-08-25 20:10 ` Junio C Hamano
2010-08-25 21:57 ` Jens Lehmann
2010-08-28 14:48 ` [PATCH 0/2] checkout: diff.ignoreSubmodules: Add test and honor per submodule settings too Jens Lehmann
2010-08-28 14:49 ` Jens Lehmann [this message]
2010-08-28 14:50 ` [PATCH 2/2] checkout: Use submodule.*.ignore settings from .git/config and .gitmodules Jens Lehmann
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=4C7921F5.1050701@web.de \
--to=jens.lehmann@web.de \
--cc=Johannes.Schindelin@gmx.de \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).