GIT-QDIFF(1)

NAME
git-qdiff - show changes in topmost patch and working tree

SYNOPSIS
git qdiff [<option> ...] [<path> ...]

DESCRIPTION
The git qdiff command displays a diff representing the changes introduced by the currently topmost Git-MQ managed patch, augmented by any additional changes which have been made within the working tree, or staged within git's index, since the patch was created, or subsequently updated by “git qrefresh”; this effectively represents the set of changes which will become the content of the topmost patch, following execution of “git qrefresh --all”.

To see changes in the working tree, or in git's index, since the last refresh of the topmost patch, use “git diff”; to see changes within the topmost patch, but excluding changes in the working tree, or in the index, use “git diff qtip^..qtip”, or “git show”.

git qdiff is implemented in terms of git diff, and supports a subset of git diff options, as itemized below; if specified, these will be passed on to git diff, to control its underlying behaviour. Additionally, if any <path> arguments are specified, the git diff output will be filtered, to display only the changes affecting files referenced by the specified paths.

OPTIONS

-a, --text
    Treat the content of all files as text.

-U<num>, --unified[=<num>]
    Generate a diff in which <num> lines of common context are displayed, rather than the default three lines.

--ignore-blank-lines
    Ignore differences which comprise only blank lines.

-b, --ignore-space-change
    Ignore changes in the lengths of white space sequences. This ignores white space at end-of-line, and considers all other sequences of one or more white space characters to be equivalent.

-w, --ignore-all-space
    Ignore white space when comparing lines. This ignores differences even if one line has white space where the other line has none.

--ignore-space-at-eol
    Ignore changes in the lengths of sequences of zero or more white space characters at end-of-line.

--stat
    Display a diffstat summary of changes.

EXIT STATUS
On successful completion, git qdiff reports an exit status code of 0. Any non-zero exit status code indicates that an error occurred.

COMPARISON WITH MERCURIAL QUEUES
Inspired by, and for the most part based on behavioural observation of Mercurial's MQ extension, the git qdiff command exhibits fundamentally the same behaviour as its hg qdiff counterpart; notable differences are:—

•   The --nodates, --reverse, -I (or --include), and -X (or --exclude) options, supported by hg qdiff, are unimplemented in git qdiff.

•   The -g (or --git), and the -p (or --show-function) options, as supported by hg qdiff, are not explicitly supported by git qdiff; however, their effects are implicitly inherent within the underlying git diff implementation. It is also worthy of note that the -p, and the -W (or --function-context) options, which are supported by git diff, exhibit different behaviour from anything which is achievable with hg qdiff.

•   hg qdiff accepts -B as a documented short-form alias for the --ignore-blank-lines option; although this is not formally documented above, git qdiff does likewise; however, use of this feature is discouraged, because git diff attributes a different, (and incompatible), meaning to its -B option.

•   The --ignore-space-at-eol option is specific to git qdiff; it is not supported by hg qdiff.

AUTHOR
Copyright (C) 2019, by Keith Marshall

This man page was written by Keith Marshall <keith@users.osdn.me>, to accompany his Git-MQ program suite. It is published under the terms of the GNU Free Documentation Licence, version 1.3, (or any later version published by the Free Software Foundation), with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts.

The Git-MQ program suite itself is distibruted under the terms of the GNU General Public Licence, version 3, (or any later version published by the Free Software Foundation).

Copies of the GNU Free Documentation Licence, and of the GNU General Public Licence, are included within the Git-MQ source distribution, in the files FDL-1.3, and LICENCE, respectively.

SEE ALSO
diff(1), git-apply(1), git-diff(1), git-show(1)