From 8ca4bef63b9dae11466f76e43ebd73239ac13e9d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Roberto=20O=2E=20Fern=C3=A1ndez=20Crisial?= Date: Tue, 8 Dec 2020 01:44:56 -0300 Subject: [PATCH 1/2] plumbing: protocol/packp, Adding object-format and filter capabilities. Fixes #220 --- plumbing/protocol/packp/capability/capability.go | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/plumbing/protocol/packp/capability/capability.go b/plumbing/protocol/packp/capability/capability.go index a12978115..8d6a56f53 100644 --- a/plumbing/protocol/packp/capability/capability.go +++ b/plumbing/protocol/packp/capability/capability.go @@ -230,6 +230,12 @@ const ( PushCert Capability = "push-cert" // SymRef symbolic reference support for better negotiation. SymRef Capability = "symref" + // ObjectFormat takes a hash algorithm as an argument, indicates that the + // server supports the given hash algorithms. + ObjectFormat Capability = "object-format" + // Filter if present, fetch-pack may send "filter" commands to request a + // partial clone or partial fetch and request that the server omit various objects from the packfile + Filter Capability = "filter" ) const DefaultAgent = "go-git/4.x" @@ -241,10 +247,11 @@ var known = map[Capability]bool{ NoProgress: true, IncludeTag: true, ReportStatus: true, DeleteRefs: true, Quiet: true, Atomic: true, PushOptions: true, AllowTipSHA1InWant: true, AllowReachableSHA1InWant: true, PushCert: true, SymRef: true, + ObjectFormat: true, Filter: true, } var requiresArgument = map[Capability]bool{ - Agent: true, PushCert: true, SymRef: true, + Agent: true, PushCert: true, SymRef: true, ObjectFormat: true, } var multipleArgument = map[Capability]bool{ From 18983029d84e5580f5475fd56fe9c6cb8575cef1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Roberto=20O=2E=20Fern=C3=A1ndez=20Crisial?= Date: Tue, 8 Dec 2020 01:44:56 -0300 Subject: [PATCH 2/2] plumbing: protocol/packp, Adding object-format and filter capabilities. Fixes #220. --- plumbing/protocol/packp/capability/capability.go | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/plumbing/protocol/packp/capability/capability.go b/plumbing/protocol/packp/capability/capability.go index a12978115..8d6a56f53 100644 --- a/plumbing/protocol/packp/capability/capability.go +++ b/plumbing/protocol/packp/capability/capability.go @@ -230,6 +230,12 @@ const ( PushCert Capability = "push-cert" // SymRef symbolic reference support for better negotiation. SymRef Capability = "symref" + // ObjectFormat takes a hash algorithm as an argument, indicates that the + // server supports the given hash algorithms. + ObjectFormat Capability = "object-format" + // Filter if present, fetch-pack may send "filter" commands to request a + // partial clone or partial fetch and request that the server omit various objects from the packfile + Filter Capability = "filter" ) const DefaultAgent = "go-git/4.x" @@ -241,10 +247,11 @@ var known = map[Capability]bool{ NoProgress: true, IncludeTag: true, ReportStatus: true, DeleteRefs: true, Quiet: true, Atomic: true, PushOptions: true, AllowTipSHA1InWant: true, AllowReachableSHA1InWant: true, PushCert: true, SymRef: true, + ObjectFormat: true, Filter: true, } var requiresArgument = map[Capability]bool{ - Agent: true, PushCert: true, SymRef: true, + Agent: true, PushCert: true, SymRef: true, ObjectFormat: true, } var multipleArgument = map[Capability]bool{