<feed xmlns='http://www.w3.org/2005/Atom'>
<title>git/diff.h, branch v2.23.2</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/git/git.git/
</subtitle>
<id>https://git.shady.money/git/atom?h=v2.23.2</id>
<link rel='self' href='https://git.shady.money/git/atom?h=v2.23.2'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/'/>
<updated>2019-07-11T21:29:27Z</updated>
<entry>
<title>range-diff: suppress line count in outer diff</title>
<updated>2019-07-11T21:29:27Z</updated>
<author>
<name>Thomas Gummerer</name>
<email>t.gummerer@gmail.com</email>
</author>
<published>2019-07-11T16:08:48Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=430be36eb53b042c447201c778b5398df887022f'/>
<id>urn:sha1:430be36eb53b042c447201c778b5398df887022f</id>
<content type='text'>
The line count in the outer diff's hunk headers of a range diff is not
all that interesting.  It merely shows how far along the inner diff
are on both sides.  That number is of no use for human readers, and
range-diffs are not meant to be machine readable.

In a subsequent commit we're going to add some more contextual
information such as the filename corresponding to the diff to the hunk
headers.  Remove the unnecessary information, and just keep the "@@"
to indicate that a new hunk of the outer diff is starting.

Signed-off-by: Thomas Gummerer &lt;t.gummerer@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'sb/format-patch-base-patch-id-fix'</title>
<updated>2019-06-13T20:18:46Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2019-06-13T20:18:46Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=8202d12fca5d482640a51c663d4d556c46dbc6b8'/>
<id>urn:sha1:8202d12fca5d482640a51c663d4d556c46dbc6b8</id>
<content type='text'>
The "--base" option of "format-patch" computed the patch-ids for
prerequisite patches in an unstable way, which has been updated to
compute in a way that is compatible with "git patch-id --stable".

* sb/format-patch-base-patch-id-fix:
  format-patch: make --base patch-id output stable
  format-patch: inform user that patch-id generation is unstable
</content>
</entry>
<entry>
<title>Merge branch 'nd/diff-parseopt'</title>
<updated>2019-05-30T17:50:44Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2019-05-30T17:50:44Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=20aa7c594fbc2e36476daae2f53d7c020306c62c'/>
<id>urn:sha1:20aa7c594fbc2e36476daae2f53d7c020306c62c</id>
<content type='text'>
A brown-paper-bag bugfix to a change already in 'master'.

* nd/diff-parseopt:
  parse-options: check empty value in OPT_INTEGER and OPT_ABBREV
  diff-parseopt: restore -U (no argument) behavior
  diff-parseopt: correct variable types that are used by parseopt
</content>
</entry>
<entry>
<title>diff-parseopt: correct variable types that are used by parseopt</title>
<updated>2019-05-29T18:04:30Z</updated>
<author>
<name>Nguyễn Thái Ngọc Duy</name>
<email>pclouds@gmail.com</email>
</author>
<published>2019-05-29T09:11:14Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=7f125ff9094bfebbb381afa19380943a088c8fcb'/>
<id>urn:sha1:7f125ff9094bfebbb381afa19380943a088c8fcb</id>
<content type='text'>
Most number-related OPT_ macros store the value in an 'int'
variable. Many of the variables in 'struct diff_options' have a
different type, but during the conversion to using parse_options() I
failed to notice and correct.

The problem was reported on s360x which is a big-endian
architechture. The variable to store '-w' option in this case is
xdl_opts, 'long' type, 8 bytes. But since parse_options() assumes
'int' (4 bytes), it will store bits in the wrong part of xdl_opts. The
problem was found on little-endian platforms because parse_options()
will accidentally store at the right part of xdl_opts.

There aren't much to say about the type change (except that 'int' for
xdl_opts should still be big enough, since Windows' long is the same
size as 'int' and nobody has complained so far). Some safety checks may
be implemented in the future to prevent class of bugs.

Reported-by: Todd Zullinger &lt;tmz@pobox.com&gt;
Signed-off-by: Nguyễn Thái Ngọc Duy &lt;pclouds@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>format-patch: make --base patch-id output stable</title>
<updated>2019-05-08T10:27:43Z</updated>
<author>
<name>Stephen Boyd</name>
<email>sboyd@kernel.org</email>
</author>
<published>2019-04-26T23:51:57Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=a8f6855f48fd474719e92eecc66c29a28fdc0f46'/>
<id>urn:sha1:a8f6855f48fd474719e92eecc66c29a28fdc0f46</id>
<content type='text'>
We weren't flushing the context each time we processed a hunk in the
patch-id generation code in diff.c, but we were doing that when we
generated "stable" patch-ids with the 'patch-id' tool. Let's port that
similar logic over from patch-id.c into diff.c so we can get the same
hash when we're generating patch-ids for 'format-patch --base=' types of
command invocations.

Cc: Xiaolong Ye &lt;xiaolong.ye@intel.com&gt;
Signed-off-by: Stephen Boyd &lt;sboyd@kernel.org&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'nd/diff-parseopt-4'</title>
<updated>2019-04-25T07:41:12Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2019-04-25T07:41:12Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=dcd6a8c09a36a500c4e612a52eba1c6c5e298951'/>
<id>urn:sha1:dcd6a8c09a36a500c4e612a52eba1c6c5e298951</id>
<content type='text'>
Fourth batch to teach the diff machinery to use the parse-options
API.

* nd/diff-parseopt-4:
  am: avoid diff_opt_parse()
  diff --no-index: use parse_options() instead of diff_opt_parse()
  range-diff: use parse_options() instead of diff_opt_parse()
  diff.c: allow --no-color-moved-ws
  diff-parseopt: convert --color-moved-ws
  diff-parseopt: convert --[no-]color-moved
  diff-parseopt: convert --inter-hunk-context
  diff-parseopt: convert --no-prefix
  diff-parseopt: convert --line-prefix
  diff-parseopt: convert --[src|dst]-prefix
  diff-parseopt: convert --[no-]abbrev
  diff-parseopt: convert --diff-filter
  diff-parseopt: convert --find-object
  diff-parseopt: convert -O
  diff-parseopt: convert --pickaxe-all|--pickaxe-regex
  diff-parseopt: convert -S|-G
  diff-parseopt: convert -l
  diff-parseopt: convert -z
  diff-parseopt: convert --ita-[in]visible-in-index
  diff-parseopt: convert --ws-error-highlight
</content>
</entry>
<entry>
<title>am: avoid diff_opt_parse()</title>
<updated>2019-03-24T13:21:24Z</updated>
<author>
<name>Nguyễn Thái Ngọc Duy</name>
<email>pclouds@gmail.com</email>
</author>
<published>2019-03-24T08:20:14Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=cdb5330a9baa64c28473fb0f446ca2242d6971fb'/>
<id>urn:sha1:cdb5330a9baa64c28473fb0f446ca2242d6971fb</id>
<content type='text'>
diff_opt_parse() is a heavy hammer to just set diff filter. But it's
the only way because of the diff_status_letters[] mapping. Add a new
API to set diff filter and use it in git-am. diff_opt_parse()'s only
remaining call site in revision.c will be gone soon and having it here
just because of git-am does not make sense.

Signed-off-by: Nguyễn Thái Ngọc Duy &lt;pclouds@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>diff --no-index: use parse_options() instead of diff_opt_parse()</title>
<updated>2019-03-24T13:21:24Z</updated>
<author>
<name>Nguyễn Thái Ngọc Duy</name>
<email>pclouds@gmail.com</email>
</author>
<published>2019-03-24T08:20:13Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=16bb3d714dcb1bf50f7f96b957c4306dc6df137e'/>
<id>urn:sha1:16bb3d714dcb1bf50f7f96b957c4306dc6df137e</id>
<content type='text'>
While at there, move exit() back to the caller. It's easier to see the
flow that way than burying it in diff-no-index.c

Signed-off-by: Nguyễn Thái Ngọc Duy &lt;pclouds@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'jk/diff-no-index-initialize'</title>
<updated>2019-03-07T00:59:59Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2019-03-07T00:59:59Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=12e5bdd9c4bfa0131b00b20be2cc48a8e2b08a2d'/>
<id>urn:sha1:12e5bdd9c4bfa0131b00b20be2cc48a8e2b08a2d</id>
<content type='text'>
"git diff --no-index" may still want to access Git goodies like
--ext-diff and --textconv, but so far these have been ignored,
which has been corrected.

* jk/diff-no-index-initialize:
  diff: reuse diff setup for --no-index case
</content>
</entry>
<entry>
<title>Merge branch 'jk/unused-params'</title>
<updated>2019-03-07T00:59:57Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2019-03-07T00:59:56Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=1dc2f8c122cfa7f8774db1395fad1873f7ad3aa8'/>
<id>urn:sha1:1dc2f8c122cfa7f8774db1395fad1873f7ad3aa8</id>
<content type='text'>
Code clean-up.

* jk/unused-params:
  ref-filter: drop unused "sz" parameters
  ref-filter: drop unused "obj" parameters
  ref-filter: drop unused buf/sz pairs
  files-backend: drop refs parameter from split_symref_update()
  pack-objects: drop unused parameter from oe_map_new_pack()
  merge-recursive: drop several unused parameters
  diff: drop complete_rewrite parameter from run_external_diff()
  diff: drop unused emit data parameter from sane_truncate_line()
  diff: drop unused color reset parameters
  diff: drop options parameter from diffcore_fix_diff_index()
</content>
</entry>
</feed>
