diff options
author | Santiago M. Mola <santi@mola.io> | 2017-07-10 18:25:28 +0200 |
---|---|---|
committer | Santiago M. Mola <santi@mola.io> | 2017-07-11 10:30:51 +0200 |
commit | 09f5f2a35f0f4c42b2def0642540f32e59fdeeb3 (patch) | |
tree | 02bfd08632ac8559e6f35cdbdb218de78a21e1e4 /plumbing/protocol/packp/updreq.go | |
parent | 6b69a1630b30c41f4563fd95aca1d647ba611adf (diff) | |
download | go-git-09f5f2a35f0f4c42b2def0642540f32e59fdeeb3.tar.gz |
improve delete support on push
* server: implement delete-refs and announce it.
* remote: check if server announced delete-refs before trying
to delete and fail fast if it does not.
Note that the client does not need no send 'delete-refs' back
to the server to be able to delete references:
```
delete-refs
-----------
If the server sends back the 'delete-refs' capability, it means that
it is capable of accepting a zero-id value as the target
value of a reference update. It is not sent back by the client, it
simply informs the client that it can be sent zero-id values
to delete references.
```
So our server implementation does not check if the client sent
delete-refs back, it just accepts deletes if it receives them.
Diffstat (limited to 'plumbing/protocol/packp/updreq.go')
-rw-r--r-- | plumbing/protocol/packp/updreq.go | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/plumbing/protocol/packp/updreq.go b/plumbing/protocol/packp/updreq.go index 0624930..b246613 100644 --- a/plumbing/protocol/packp/updreq.go +++ b/plumbing/protocol/packp/updreq.go @@ -42,6 +42,7 @@ func NewReferenceUpdateRequest() *ReferenceUpdateRequest { // - report-status // - ofs-delta // - ref-delta +// - delete-refs // It leaves up to the user to add the following capabilities later: // - atomic // - ofs-delta |