aboutsummaryrefslogtreecommitdiffstats
path: root/plumbing/transport/internal
diff options
context:
space:
mode:
authorSantiago M. Mola <santi@mola.io>2017-06-12 11:26:27 +0200
committerSantiago M. Mola <santi@mola.io>2017-06-13 14:57:40 +0200
commit20637689e489758b36d46e2409e20eb4fa703e73 (patch)
tree4b0b5c11ceef093236300f2627c73851d7b40597 /plumbing/transport/internal
parent8dee150a302e98c26b92133a80d6b43e4cb31a87 (diff)
downloadgo-git-20637689e489758b36d46e2409e20eb4fa703e73.tar.gz
plumbing/transport: detect git protocol "no such repository" error
Diffstat (limited to 'plumbing/transport/internal')
-rw-r--r--plumbing/transport/internal/common/common.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/plumbing/transport/internal/common/common.go b/plumbing/transport/internal/common/common.go
index 7001d05..41be776 100644
--- a/plumbing/transport/internal/common/common.go
+++ b/plumbing/transport/internal/common/common.go
@@ -337,6 +337,7 @@ var (
bitbucketRepoNotFoundErr = "conq: repository does not exist."
localRepoNotFoundErr = "does not appear to be a git repository"
gitProtocolNotFoundErr = "ERR \n Repository not found."
+ gitProtocolNoSuchErr = "ERR no such repository"
)
func isRepoNotFoundError(s string) bool {
@@ -356,6 +357,10 @@ func isRepoNotFoundError(s string) bool {
return true
}
+ if strings.HasPrefix(s, gitProtocolNoSuchErr) {
+ return true
+ }
+
return false
}