Page MenuHomePhabricator

[DRAFT] Parse the Git wire protocol in receive-pack
Changes PlannedPublic

Authored by epriestley on May 20 2016, 6:14 PM.



Ref T5000. Git's protocol is mostly fairly parsable. It has PACK blobs which are trickier to parse, but we don't currently need to decode them (and I think we may never need to decode them: we only need to rewrite refs and response codes, not object content).

To rewrite the actual response, we only need to rewrite this:

0033ng refs/heads/master pre-receive hook declined\n

...into this:

0019ok refs/heads/master \n

...which is pretty reasonable. This doesn't emit or interpret frames and isn't suitable to upstream since it also writes all of the protocol out to tempfiles, but I'm reasonably confident I can estimate T5000 now.

Test Plan


Diff Detail

rP Phabricator
Lint OK
Unit Tests OK
Build Status
Buildable 12284
Build 15527: Run Core Tests
Build 15526: arc lint + arc unit

Event Timeline

epriestley updated this revision to Diff 38414.May 20 2016, 6:14 PM
epriestley retitled this revision from to [DRAFT] Parse the Git wire protocol in receive-pack.
epriestley updated this object.
epriestley edited the test plan for this revision. (Show Details)
epriestley planned changes to this revision.May 20 2016, 6:16 PM

This is just for reference.

Treri added a subscriber: Treri.May 17 2017, 7:08 AM