<feed xmlns='http://www.w3.org/2005/Atom'>
<title>git/Documentation/technical, branch v2.18.2</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/git/git.git/
</subtitle>
<id>https://git.shady.money/git/atom?h=v2.18.2</id>
<link rel='self' href='https://git.shady.money/git/atom?h=v2.18.2'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/'/>
<updated>2018-05-30T05:04:11Z</updated>
<entry>
<title>Merge branch 'ab/get-short-oid'</title>
<updated>2018-05-30T05:04:11Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2018-05-30T05:04:11Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=ab48bc0aeadd7f6b661bc125a913e1c7d145cd5e'/>
<id>urn:sha1:ab48bc0aeadd7f6b661bc125a913e1c7d145cd5e</id>
<content type='text'>
When a short hexadecimal string is used to name an object but there
are multiple objects that share the string as the prefix of their
names, the code lists these ambiguous candidates in a help message.
These object names are now sorted according to their types for
easier eyeballing.

* ab/get-short-oid:
  get_short_oid: sort ambiguous objects by type, then SHA-1
  sha1-name.c: move around the collect_ambiguous() function
  git-p4: change "commitish" typo to "committish"
  sha1-array.h: align function arguments
  sha1-name.c: remove stray newline
</content>
</entry>
<entry>
<title>Merge branch 'jt/partial-clone-proto-v2'</title>
<updated>2018-05-30T05:04:10Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2018-05-30T05:04:10Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=54db5c0e1edf0d92bd474f515fab349b98c18a24'/>
<id>urn:sha1:54db5c0e1edf0d92bd474f515fab349b98c18a24</id>
<content type='text'>
Transfer protocol v2 learned to support the partial clone.

* jt/partial-clone-proto-v2:
  {fetch,upload}-pack: support filter in protocol v2
  upload-pack: read config when serving protocol v2
  upload-pack: fix error message typo
</content>
</entry>
<entry>
<title>Merge branch 'js/deprecate-grafts'</title>
<updated>2018-05-23T05:38:17Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2018-05-23T05:38:17Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=352cf6cfe138b1dbcf9c105c91ca793b67511d7b'/>
<id>urn:sha1:352cf6cfe138b1dbcf9c105c91ca793b67511d7b</id>
<content type='text'>
The functionality of "$GIT_DIR/info/grafts" has been superseded by
the "refs/replace/" mechanism for some time now, but the internal
code had support for it in many places, which has been cleaned up
in order to drop support of the "grafts" mechanism.

* js/deprecate-grafts:
  Remove obsolete script to convert grafts to replace refs
  technical/shallow: describe why shallow cannot use replace refs
  technical/shallow: stop referring to grafts
  filter-branch: stop suggesting to use grafts
  Deprecate support for .git/info/grafts
  Add a test for `git replace --convert-graft-file`
  replace: introduce --convert-graft-file
  replace: prepare create_graft() for converting graft files wholesale
  replace: "libify" create_graft() and callees
  replace: avoid using die() to indicate a bug
  commit: Let the callback of for_each_mergetag return on error
  argv_array: offer to split a string by whitespace
</content>
</entry>
<entry>
<title>Merge branch 'bw/server-options'</title>
<updated>2018-05-23T05:38:15Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2018-05-23T05:38:15Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=41267e96972d5a158298f777caecd7433a1b1a94'/>
<id>urn:sha1:41267e96972d5a158298f777caecd7433a1b1a94</id>
<content type='text'>
The transport protocol v2 is getting updated further.

* bw/server-options:
  fetch: send server options when using protocol v2
  ls-remote: send server options when using protocol v2
  serve: introduce the server-option capability
</content>
</entry>
<entry>
<title>Merge branch 'nd/pack-format-doc'</title>
<updated>2018-05-23T05:38:11Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2018-05-23T05:38:11Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=b5771985263f4bcf500b71e6b0a2fe1164f612a0'/>
<id>urn:sha1:b5771985263f4bcf500b71e6b0a2fe1164f612a0</id>
<content type='text'>
Doc update.

* nd/pack-format-doc:
  pack-format.txt: more details on pack file format
</content>
</entry>
<entry>
<title>Merge branch 'ao/config-api-doc'</title>
<updated>2018-05-23T05:38:10Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2018-05-23T05:38:10Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=d9a0ddc217b74615b901ad4dfdde04bfbde59770'/>
<id>urn:sha1:d9a0ddc217b74615b901ad4dfdde04bfbde59770</id>
<content type='text'>
Doc update.

* ao/config-api-doc:
  doc: fix config API documentation about config_with_options
</content>
</entry>
<entry>
<title>pack-format.txt: more details on pack file format</title>
<updated>2018-05-13T01:20:03Z</updated>
<author>
<name>Nguyễn Thái Ngọc Duy</name>
<email>pclouds@gmail.com</email>
</author>
<published>2018-05-11T06:55:23Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=011b648646fcf1f467336ac6bbf46145501c0f12'/>
<id>urn:sha1:011b648646fcf1f467336ac6bbf46145501c0f12</id>
<content type='text'>
The current document mentions OBJ_* constants without their actual
values. A git developer would know these are from cache.h but that's
not very friendly to a person who wants to read this file to implement
a pack file parser.

Similarly, the deltified representation is not documented at all (the
"document" is basically patch-delta.c). Translate that C code to
English with a bit more about what ofs-delta and ref-delta mean.

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>get_short_oid: sort ambiguous objects by type, then SHA-1</title>
<updated>2018-05-11T05:43:23Z</updated>
<author>
<name>Ævar Arnfjörð Bjarmason</name>
<email>avarab@gmail.com</email>
</author>
<published>2018-05-10T12:43:02Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=5cc044e02571e93048160d94e64fe6d8dd96597e'/>
<id>urn:sha1:5cc044e02571e93048160d94e64fe6d8dd96597e</id>
<content type='text'>
Change the output emitted when an ambiguous object is encountered so
that we show tags first, then commits, followed by trees, and finally
blobs. Within each type we show objects in hashcmp() order. Before
this change the objects were only ordered by hashcmp().

The reason for doing this is that the output looks better as a result,
e.g. the v2.17.0 tag before this change on "git show e8f2" would
display:

    hint: The candidates are:
    hint:   e8f2093055 tree
    hint:   e8f21caf94 commit 2013-06-24 - bash prompt: print unique detached HEAD abbreviated object name
    hint:   e8f21d02f7 blob
    hint:   e8f21d577c blob
    hint:   e8f25a3a50 tree
    hint:   e8f26250fa commit 2017-02-03 - Merge pull request #996 from jeffhostetler/jeffhostetler/register_rename_src
    hint:   e8f2650052 tag v2.17.0
    hint:   e8f2867228 blob
    hint:   e8f28d537c tree
    hint:   e8f2a35526 blob
    hint:   e8f2bc0c06 commit 2015-05-10 - Documentation: note behavior for multiple remote.url entries
    hint:   e8f2cf6ec0 tree

Now we'll instead show:

    hint:   e8f2650052 tag v2.17.0
    hint:   e8f21caf94 commit 2013-06-24 - bash prompt: print unique detached HEAD abbreviated object name
    hint:   e8f26250fa commit 2017-02-03 - Merge pull request #996 from jeffhostetler/jeffhostetler/register_rename_src
    hint:   e8f2bc0c06 commit 2015-05-10 - Documentation: note behavior for multiple remote.url entries
    hint:   e8f2093055 tree
    hint:   e8f25a3a50 tree
    hint:   e8f28d537c tree
    hint:   e8f2cf6ec0 tree
    hint:   e8f21d02f7 blob
    hint:   e8f21d577c blob
    hint:   e8f2867228 blob
    hint:   e8f2a35526 blob

Since we show the commit data in the output that's nicely aligned once
we sort by object type. The decision to show tags before commits is
pretty arbitrary. I don't want to order by object_type since there
tags come last after blobs, which doesn't make sense if we want to
show the most important things first.

I could display them after commits, but it's much less likely that
we'll display a tag, so if there is one it makes sense to show it
prominently at the top.

A note on the implementation: Derrick rightly pointed out[1] that
we're bending over backwards here in get_short_oid() to first
de-duplicate the list, and then emit it, but could simply do it in one
step.

The reason for that is that oid_array_for_each_unique() doesn't
actually require that the array be sorted by oid_array_sort(), it just
needs to be sorted in some order that guarantees that all objects with
the same ID are adjacent to one another, which (barring a hash
collision, which'll be someone else's problem) the sort_ambiguous()
function does.

I agree that would be simpler for this code, and had forgotten why I
initially wrote it like this[2]. But on further reflection I think
it's better to do more work here just so we're not underhandedly using
the oid-array API where we lie about the list being sorted. That would
break any subsequent use of oid_array_lookup() in subtle ways.

I could get around that by hacking the API itself to support this
use-case and documenting it, which I did as a WIP patch in [3], but I
think it's too much code smell just for this one call site. It's
simpler for the API to just introduce a oid_array_for_each() function
to eagerly spew out the list without sorting or de-duplication, and
then do the de-duplication and sorting in two passes.

1. https://public-inbox.org/git/20180501130318.58251-1-dstolee@microsoft.com/
2. https://public-inbox.org/git/876047ze9v.fsf@evledraar.gmail.com/
3. https://public-inbox.org/git/874ljrzctc.fsf@evledraar.gmail.com/

Helped-by: Derrick Stolee &lt;dstolee@microsoft.com&gt;
Signed-off-by: Ævar Arnfjörð Bjarmason &lt;avarab@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>doc: fix config API documentation about config_with_options</title>
<updated>2018-05-11T01:26:33Z</updated>
<author>
<name>Antonio Ospite</name>
<email>ao2@ao2.it</email>
</author>
<published>2018-05-09T13:16:28Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=f7997e36821d816710658874784cd538d134dee2'/>
<id>urn:sha1:f7997e36821d816710658874784cd538d134dee2</id>
<content type='text'>
In commit dc8441fdb ("config: don't implicitly use gitdir or commondir",
2017-06-14) the function git_config_with_options was renamed to
config_with_options to better reflect the fact that it does not access
the git global config or the repo config by default.

However Documentation/technical/api-config.txt still refers to the
previous name, fix that.

While at it also update the documentation about the extra parameters,
because they too changed since the initial definition.

Signed-off-by: Antonio Ospite &lt;ao2@ao2.it&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'ds/commit-graph'</title>
<updated>2018-05-08T06:59:20Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2018-05-08T06:59:20Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=b10edb2df55241b2e042b3d5473537904d09d193'/>
<id>urn:sha1:b10edb2df55241b2e042b3d5473537904d09d193</id>
<content type='text'>
Precompute and store information necessary for ancestry traversal
in a separate file to optimize graph walking.

* ds/commit-graph:
  commit-graph: implement "--append" option
  commit-graph: build graph from starting commits
  commit-graph: read only from specific pack-indexes
  commit: integrate commit graph with commit parsing
  commit-graph: close under reachability
  commit-graph: add core.commitGraph setting
  commit-graph: implement git commit-graph read
  commit-graph: implement git-commit-graph write
  commit-graph: implement write_commit_graph()
  commit-graph: create git-commit-graph builtin
  graph: add commit graph design document
  commit-graph: add format document
  csum-file: refactor finalize_hashfile() method
  csum-file: rename hashclose() to finalize_hashfile()
</content>
</entry>
</feed>
