aboutsummaryrefslogtreecommitdiffstats
path: root/remote.go
diff options
context:
space:
mode:
authorMáximo Cuadros <mcuadros@gmail.com>2015-11-05 01:48:14 +0100
committerMáximo Cuadros <mcuadros@gmail.com>2015-11-05 01:48:14 +0100
commita80d56b21142096f458758405736f3d567c175f5 (patch)
tree2284cf4793c18c2dba32568390f69083cf116956 /remote.go
parent1d6b13537129018bc7e866ea42ec835e565c6469 (diff)
downloadgo-git-a80d56b21142096f458758405736f3d567c175f5.tar.gz
remote: info method
Diffstat (limited to 'remote.go')
-rw-r--r--remote.go7
1 files changed, 6 insertions, 1 deletions
diff --git a/remote.go b/remote.go
index 1914e67..87ea27e 100644
--- a/remote.go
+++ b/remote.go
@@ -43,12 +43,17 @@ func (r *Remote) Connect() error {
return nil
}
+// Info returns the git-upload-pack info
+func (r *Remote) Info() *common.GitUploadPackInfo {
+ return r.upInfo
+}
+
// Capabilities returns the remote capabilities
func (r *Remote) Capabilities() *common.Capabilities {
return r.upInfo.Capabilities
}
-// DefaultBranch retrieve the name of the remote's default branch
+// DefaultBranch returns the name of the remote's default branch
func (r *Remote) DefaultBranch() string {
return r.upInfo.Capabilities.SymbolicReference("HEAD")
}