<feed xmlns='http://www.w3.org/2005/Atom'>
<title>git/send-pack.c, branch v2.30.2</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/git/git.git/
</subtitle>
<id>https://git.shady.money/git/atom?h=v2.30.2</id>
<link rel='self' href='https://git.shady.money/git/atom?h=v2.30.2'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/'/>
<updated>2020-12-08T23:11:20Z</updated>
<entry>
<title>Merge branch 'js/trace2-session-id'</title>
<updated>2020-12-08T23:11:20Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2020-12-08T23:11:20Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=01b8886a62243c93cc57758bbaae08e11b09b9e1'/>
<id>urn:sha1:01b8886a62243c93cc57758bbaae08e11b09b9e1</id>
<content type='text'>
The transport layer was taught to optionally exchange the session
ID assigned by the trace2 subsystem during fetch/push transactions.

* js/trace2-session-id:
  receive-pack: log received client session ID
  send-pack: advertise session ID in capabilities
  upload-pack, serve: log received client session ID
  fetch-pack: advertise session ID in capabilities
  transport: log received server session ID
  serve: advertise session ID in v2 capabilities
  receive-pack: advertise session ID in v0 capabilities
  upload-pack: advertise session ID in v0 capabilities
  trace2: add a public function for getting the SID
  docs: new transfer.advertiseSID option
  docs: new capability to advertise session IDs
</content>
</entry>
<entry>
<title>Merge branch 'jk/stop-pack-objects-when-push-is-killed'</title>
<updated>2020-12-03T08:18:06Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2020-12-03T08:18:06Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=adae5df5d22d97888987d6e070a91a7b04289c6f'/>
<id>urn:sha1:adae5df5d22d97888987d6e070a91a7b04289c6f</id>
<content type='text'>
"git push" that is killed may leave a pack-objects process behind,
still computing to find a good compression, wasting cycles.  This
has been corrected.

* jk/stop-pack-objects-when-push-is-killed:
  send-pack: kill pack-objects helper on signal or exit
</content>
</entry>
<entry>
<title>send-pack: kill pack-objects helper on signal or exit</title>
<updated>2020-11-21T21:55:17Z</updated>
<author>
<name>Jeff King</name>
<email>peff@peff.net</email>
</author>
<published>2020-11-21T00:29:21Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=8b59935114d9dafd737a7674ccf3787e7ffc61c9'/>
<id>urn:sha1:8b59935114d9dafd737a7674ccf3787e7ffc61c9</id>
<content type='text'>
We spawn an external pack-objects process to actually send
objects to the remote side. If we are killed by a signal
during this process, the pack-objects will keep running and
complete the push, which may surprise the user. We should
take it down when we go down.

Signed-off-by: Jeff King &lt;peff@peff.net&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>send-pack: advertise session ID in capabilities</title>
<updated>2020-11-12T02:26:53Z</updated>
<author>
<name>Josh Steadmon</name>
<email>steadmon@google.com</email>
</author>
<published>2020-11-11T23:29:33Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=8c4870029dd084bc030e1b5383fa13358bcce236'/>
<id>urn:sha1:8c4870029dd084bc030e1b5383fa13358bcce236</id>
<content type='text'>
When the server sent a session-id capability and transfer.advertiseSID
is true, advertise send-pack's own session ID back to the server.

Signed-off-by: Josh Steadmon &lt;steadmon@google.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'sk/force-if-includes'</title>
<updated>2020-10-27T22:09:49Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2020-10-27T22:09:49Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=de0a7effc86aadf6177fdcea52b5ae24c7a85911'/>
<id>urn:sha1:de0a7effc86aadf6177fdcea52b5ae24c7a85911</id>
<content type='text'>
"git push --force-with-lease[=&lt;ref&gt;]" can easily be misused to lose
commits unless the user takes good care of their own "git fetch".
A new option "--force-if-includes" attempts to ensure that what is
being force-pushed was created after examining the commit at the
tip of the remote ref that is about to be force-replaced.

* sk/force-if-includes:
  t, doc: update tests, reference for "--force-if-includes"
  push: parse and set flag for "--force-if-includes"
  push: add reflog check for "--force-if-includes"
</content>
</entry>
<entry>
<title>push: add reflog check for "--force-if-includes"</title>
<updated>2020-10-03T16:59:18Z</updated>
<author>
<name>Srinidhi Kaushik</name>
<email>shrinidhi.kaushik@gmail.com</email>
</author>
<published>2020-10-03T12:10:44Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=99a1f9ae10816c2527d7197a5dde714f980b712b'/>
<id>urn:sha1:99a1f9ae10816c2527d7197a5dde714f980b712b</id>
<content type='text'>
Add a check to verify if the remote-tracking ref of the local branch
is reachable from one of its "reflog" entries.

The check iterates through the local ref's reflog to see if there
is an entry for the remote-tracking ref and collecting any commits
that are seen, into a list; the iteration stops if an entry in the
reflog matches the remote ref or if the entry timestamp is older
the latest entry of the remote ref's "reflog". If there wasn't an
entry found for the remote ref, "in_merge_bases_many()" is called
to check if it is reachable from the list of collected commits.

When a local branch that is based on a remote ref, has been rewound
and is to be force pushed on the remote, "--force-if-includes" runs
a check that ensures any updates to the remote-tracking ref that may
have happened (by push from another repository) in-between the time
of the last update to the local branch (via "git-pull", for instance)
and right before the time of push, have been integrated locally
before allowing a forced update.

If the new option is passed without specifying "--force-with-lease",
or specified along with "--force-with-lease=&lt;refname&gt;:&lt;expect&gt;" it
is a "no-op".

Signed-off-by: Srinidhi Kaushik &lt;shrinidhi.kaushik@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'hx/push-atomic-with-cert'</title>
<updated>2020-09-25T22:25:41Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2020-09-25T22:25:41Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=b5847b9fab0aedc3b2642ccd123da7dd95da1376'/>
<id>urn:sha1:b5847b9fab0aedc3b2642ccd123da7dd95da1376</id>
<content type='text'>
"git push" that wants to be atomic and wants to send push
certificate learned not to prepare and sign the push certificate
when it fails the local check (hence due to atomicity it is known
that no certificate is needed).

* hx/push-atomic-with-cert:
  send-pack: run GPG after atomic push checking
</content>
</entry>
<entry>
<title>Merge branch 'jx/proc-receive-hook'</title>
<updated>2020-09-25T22:25:39Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2020-09-25T22:25:39Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=6c430a647cb990fc856d328733fa59e1fafadb97'/>
<id>urn:sha1:6c430a647cb990fc856d328733fa59e1fafadb97</id>
<content type='text'>
"git receive-pack" that accepts requests by "git push" learned to
outsource most of the ref updates to the new "proc-receive" hook.

* jx/proc-receive-hook:
  doc: add documentation for the proc-receive hook
  transport: parse report options for tracking refs
  t5411: test updates of remote-tracking branches
  receive-pack: new config receive.procReceiveRefs
  doc: add document for capability report-status-v2
  New capability "report-status-v2" for git-push
  receive-pack: feed report options to post-receive
  receive-pack: add new proc-receive hook
  t5411: add basic test cases for proc-receive hook
  transport: not report a non-head push as a branch
</content>
</entry>
<entry>
<title>send-pack: run GPG after atomic push checking</title>
<updated>2020-09-19T22:56:39Z</updated>
<author>
<name>Han Xin</name>
<email>hanxin.hx@alibaba-inc.com</email>
</author>
<published>2020-09-19T14:47:50Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=a4f324a423ddfe3680bf6105f8c113d0e76305a0'/>
<id>urn:sha1:a4f324a423ddfe3680bf6105f8c113d0e76305a0</id>
<content type='text'>
The refs update commands can be sent to the server side in two different
ways: GPG-signed or unsigned.  We should run these two operations in the
same "Finally, tell the other end!" code block, but they are seperated
by the "Clear the status for each ref" code block.  This will result in
a slight performance loss, because the failed atomic push will still
perform unnecessary preparations for shallow advertise and GPG-signed
commands buffers, and user may have to be bothered by the (possible) GPG
passphrase input when there is nothing to sign.

Add a new test case to t5534 to ensure GPG will not be called when the
GPG-signed atomic push fails.

Signed-off-by: Han Xin &lt;hanxin.hx@alibaba-inc.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>New capability "report-status-v2" for git-push</title>
<updated>2020-08-27T19:47:47Z</updated>
<author>
<name>Jiang Xin</name>
<email>zhiyou.jx@alibaba-inc.com</email>
</author>
<published>2020-08-27T15:45:46Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=63518a574a3a4b8c6f152b29cb1b6d1f66f6e6c7'/>
<id>urn:sha1:63518a574a3a4b8c6f152b29cb1b6d1f66f6e6c7</id>
<content type='text'>
The new introduced "proc-receive" hook may handle a command for a
pseudo-reference with a zero-old as its old-oid, while the hook may
create or update a reference with different name, different new-oid,
and different old-oid (the reference may exist already with a non-zero
old-oid).  Current "report-status" protocol cannot report the status for
such reference rewrite.

Add new capability "report-status-v2" and new report protocol which is
not backward compatible for report of git-push.

If a user pushes to a pseudo-reference "refs/for/master/topic", and
"receive-pack" creates two new references "refs/changes/23/123/1" and
"refs/changes/24/124/1", for client without the knowledge of
"report-status-v2", "receive-pack" will only send "ok/ng" directives in
the report, such as:

    ok ref/for/master/topic

But for client which has the knowledge of "report-status-v2",
"receive-pack" will use "option" directives to report more attributes
for the reference given by the above "ok/ng" directive.

    ok refs/for/master/topic
    option refname refs/changes/23/123/1
    option new-oid &lt;new-oid&gt;
    ok refs/for/master/topic
    option refname refs/changes/24/124/1
    option new-oid &lt;new-oid&gt;

The client will report two new created references to the end user.

Suggested-by: Junio C Hamano &lt;gitster@pobox.com&gt;
Suggested-by: Jeff King &lt;peff@peff.net&gt;
Signed-off-by: Jiang Xin &lt;zhiyou.jx@alibaba-inc.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
</feed>
