From: John Cheng <johnlicheng@gmail.com>
To: git@vger.kernel.org
Subject: Misleading documentation for git-diff-files (diff-filter)
Date: Wed, 3 Jan 2018 08:07:03 -0800 [thread overview]
Message-ID: <CAJzZBAT--X8GXg_knege_pZ8A=_Qk9nyMCLaoRMvjhUFGQYsZA@mail.gmail.com> (raw)
I originally asked this question on stackoverflow
(https://stackoverflow.com/q/48039277).
I wanted to know if git diff-files shows files that are not in the
index but are in the working tree. The documentation says you can
supply --diff-filter=A, which will select file "that are added".
However, git-diff-files (appears) to never show any files with the
status of "A".
It seems like the cause is that git diff-files includes
diff-options.txt which uses a standard template for --diff-filter
which includes the "A" option. Perhaps a clarification can be added?
Compares the files in the working tree and the index. When paths
are specified, compares only those named paths. Otherwise all
entries in the index are compared. The output format is the
same as for 'git diff-index' and 'git diff-tree'. Files not in the index are
not compared.
--
---
John L Cheng
next reply other threads:[~2018-01-03 16:07 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-01-03 16:07 John Cheng [this message]
2018-01-03 23:53 ` Misleading documentation for git-diff-files (diff-filter) Junio C Hamano
2018-01-04 15:53 ` John Cheng
2018-01-04 16:49 ` Jeff King
2018-01-04 19:09 ` Junio C Hamano
2018-01-04 19:11 ` John Cheng
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
List information: http://vger.kernel.org/majordomo-info.html
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAJzZBAT--X8GXg_knege_pZ8A=_Qk9nyMCLaoRMvjhUFGQYsZA@mail.gmail.com' \
--to=johnlicheng@gmail.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.
Code repositories for project(s) associated with this public inbox
https://80x24.org/mirrors/git.git
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 read-only IMAP folder(s) and NNTP newsgroup(s).