git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Paul Gortmaker <paul.gortmaker@windriver.com>
To: git@vger.kernel.org
Subject: Bug in "git diff --quiet" handling.
Date: Mon, 11 Apr 2011 17:07:33 -0400	[thread overview]
Message-ID: <4DA36D95.6060108@windriver.com> (raw)

I came across this when I was mistakenly thinking I could use "--quiet" to
stop the output of git format-patch giving the 0001-somecommit.patch names as
it generated them.

It was then when I read the man page and found it is passed into git diff and
is supposed to disable all output.  The interesting thing, is that it only
seems to do this on every other commit it format-patches, as shown
below.

I'm assuming this is a bug, since I can't imagine what use case would have
every alternate patch being output as useful.  If I get a chance, I'll take
a look at the code and see if I can figure out what is going on, but I
figured I'd mention it 1st in case it triggered an "Oh yeah it is XYZ"
in someones memory.

Paul.

---

Script started on Mon 11 Apr 2011 04:50:22 PM EDT
paul@dv2000:~/git/git$ git --version
git version 1.7.4.4
paul@dv2000:~/git/git$ git format-patch --quiet -o foo HEAD~10..HEAD
paul@dv2000:~/git/git$ ls -l foo
total 60
-rw-r--r-- 1 paul paul 2960 2011-04-11 16:50 0001-fetch-pull-recurse-into-submodules-when-necessary.patch
-rw-r--r-- 1 paul paul    0 2011-04-11 16:50 0002-fetch-pull-Add-the-on-demand-value-to-the-recurse-su.patch
-rw-r--r-- 1 paul paul 1514 2011-04-11 16:50 0003-config-teach-the-fetch.recurseSubmodules-option-the-.patch
-rw-r--r-- 1 paul paul    0 2011-04-11 16:50 0004-Submodules-Add-on-demand-value-for-the-fetchRecurseS.patch
-rw-r--r-- 1 paul paul 1391 2011-04-11 16:50 0005-fetch-pull-Don-t-recurse-into-a-submodule-when-commi.patch
-rw-r--r-- 1 paul paul    0 2011-04-11 16:50 0006-submodule-update-Don-t-fetch-when-the-submodule-comm.patch
-rw-r--r-- 1 paul paul 1381 2011-04-11 16:50 0007-fetch-pull-Describe-recurse-submodule-restrictions-i.patch
-rw-r--r-- 1 paul paul    0 2011-04-11 16:50 0008-remote-disallow-some-nonsensical-option-combinations.patch
-rw-r--r-- 1 paul paul 3801 2011-04-11 16:50 0009-remote-separate-the-concept-of-push-and-fetch-mirror.patch
-rw-r--r-- 1 paul paul    0 2011-04-11 16:50 0010-remote-deprecate-mirror.patch
-rw-r--r-- 1 paul paul 3172 2011-04-11 16:50 0011-submodule-process-conflicting-submodules-only-once.patch
-rw-r--r-- 1 paul paul    0 2011-04-11 16:50 0012-revisions.txt-consistent-use-of-quotes.patch
-rw-r--r-- 1 paul paul 9679 2011-04-11 16:50 0013-revisions.txt-structure-with-a-labelled-list.patch
-rw-r--r-- 1 paul paul    0 2011-04-11 16:50 0014-log-cherry-pick-documentation-regression-fix.patch
-rw-r--r-- 1 paul paul 1826 2011-04-11 16:50 0015-compat-add-missing-include-sys-resource.h.patch
-rw-r--r-- 1 paul paul    0 2011-04-11 16:50 0016-pull-do-not-clobber-untracked-files-on-initial-pull.patch
-rw-r--r-- 1 paul paul 1743 2011-04-11 16:50 0017-Start-preparing-for-1.7.4.4.patch
-rw-r--r-- 1 paul paul    0 2011-04-11 16:50 0018-gitweb-Fix-parsing-of-negative-fractional-timezones-.patch
-rw-r--r-- 1 paul paul 1089 2011-04-11 16:50 0019-Documentation-trivial-grammar-fix-in-core.worktree-d.patch
-rw-r--r-- 1 paul paul    0 2011-04-11 16:50 0020-revisions.txt-language-improvements.patch
-rw-r--r-- 1 paul paul 1114 2011-04-11 16:50 0021-Git-1.7.4.4.patch
-rw-r--r-- 1 paul paul    0 2011-04-11 16:50 0022-Git-1.7.5-rc1.patch
-rw-r--r-- 1 paul paul 4996 2011-04-11 16:50 0023-git-p4-replace-each-tab-with-8-spaces-for-consistenc.patch
paul@dv2000:~/git/git$ exit
exit
Script done on Mon 11 Apr 2011 04:51:34 PM EDT

             reply	other threads:[~2011-04-11 21:08 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-04-11 21:07 Paul Gortmaker [this message]
2011-04-11 21:35 ` Bug in "git diff --quiet" handling Junio C Hamano
2011-04-12 15:51   ` [PATCH] format-patch: document --quiet option Carlos Martín Nieto
2011-04-12 19:07     ` Junio C Hamano
2011-04-12 19:52       ` Junio C Hamano
2011-04-13  9:29         ` Carlos Martín Nieto
2011-04-12 15:35 ` [PATCH] format-patch: don't pass on the --quiet flag Carlos Martín Nieto
2011-04-12 18:56   ` Junio C Hamano
2011-04-13  9:26     ` Carlos Martín Nieto
2011-04-13 12:10       ` [PATCH] whatchanged: always show the header Carlos Martín Nieto
2011-04-13 15:58         ` Junio C Hamano
2011-04-13 19:38           ` Carlos Martín Nieto
2011-04-14 14:28           ` [PATCH] log: convert to parse-options Carlos Martín Nieto
2011-04-14 17:08             ` Junio C Hamano
2011-04-19 12:33               ` =?UTF-8?q?Carlos=20Mart=C3=ADn=20Nieto?=
2011-04-20  2:38                 ` Jeff King
2011-04-20 14:51                   ` Carlos Martín Nieto

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=4DA36D95.6060108@windriver.com \
    --to=paul.gortmaker@windriver.com \
    --cc=git@vger.kernel.org \
    /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).