aboutsummaryrefslogtreecommitdiffstats
path: root/plumbing/transport/common.go
diff options
context:
space:
mode:
authorSantiago M. Mola <santi@mola.io>2016-11-28 09:57:38 +0100
committerGitHub <noreply@github.com>2016-11-28 09:57:38 +0100
commit68893edf9ddc3de181431f1552e3b773cb66f080 (patch)
treef45e5fa18e10168a278b7d0ed7dea984ff9969f7 /plumbing/transport/common.go
parentf9adb3565b36ba1573102f954d0ee916009efac2 (diff)
downloadgo-git-68893edf9ddc3de181431f1552e3b773cb66f080.tar.gz
remove old types from transport and use packp (#142)
* protocol: move UploadPackRequest to protocol. * UploadPackRequest is now defined as an embedding of UploadRequest and UploadHaves. * Move http encoding specific code from UploadPackRequest to transport/http. * rename UlReq to UploadRequest * packp: move AdvRefs Encoder/Decoder to Encode/Decode methods. * packp: move UploadRequest Encoder/Decoder to Encode/Decode methods. * packp: Remove transport.UploadPackInfo in favor of packp. AdvRefs.
Diffstat (limited to 'plumbing/transport/common.go')
-rw-r--r--plumbing/transport/common.go7
1 files changed, 4 insertions, 3 deletions
diff --git a/plumbing/transport/common.go b/plumbing/transport/common.go
index 8329069..2f6fcee 100644
--- a/plumbing/transport/common.go
+++ b/plumbing/transport/common.go
@@ -20,6 +20,7 @@ import (
"regexp"
"gopkg.in/src-d/go-git.v4/plumbing"
+ "gopkg.in/src-d/go-git.v4/plumbing/protocol/packp"
)
var (
@@ -63,10 +64,10 @@ type FetchPackSession interface {
// AdvertisedReferences retrieves the advertised references for a
// repository. It should be called before FetchPack, and it cannot be
// called after FetchPack.
- AdvertisedReferences() (*UploadPackInfo, error)
+ AdvertisedReferences() (*packp.AdvRefs, error)
// FetchPack takes a request and returns a reader for the packfile
// received from the server.
- FetchPack(req *UploadPackRequest) (io.ReadCloser, error)
+ FetchPack(req *packp.UploadPackRequest) (io.ReadCloser, error)
}
// FetchPackSession represents a git-send-pack session.
@@ -78,7 +79,7 @@ type SendPackSession interface {
// AdvertisedReferences retrieves the advertised references for a
// repository. It should be called before FetchPack, and it cannot be
// called after FetchPack.
- AdvertisedReferences() (*UploadPackInfo, error)
+ AdvertisedReferences() (*packp.AdvRefs, error)
// UpdateReferences sends an update references request and returns a
// writer to be used for packfile writing.
//TODO: Complete signature.