From 0a99049195aff55f007fc4dfd48e3ec2b4d5f602 Mon Sep 17 00:00:00 2001 From: Dmitri Shuralyov Date: Sun, 27 Jan 2019 13:37:01 -0500 Subject: [PATCH] go/vcs: remove go.googlesource.com vcsPath entry This change synchronizes the absence of a special case entry for go.googlesource.com import paths in cmd/go/internal/get to this package. It seems it was added to x/tools/go/vcs in CL 180540043, but it was never added to cmd/go/internal/get itself. Having an go.googlesource.com entry here but not in cmd/go/internal/get means the import path resolution logic diverges from that of the go command, which is counter to the goal of this package. After this change is applied, vcs.RepoRootForImportPathStatic reports correct results for import paths like "go.googlesource.com/scratch.git" (resolving it without an error) and "go.googlesource.com/scratch" (reporting an error). Updates golang/go#11490 Change-Id: I0b1c959675d9e20205a587a06d734fcd103ebf91 Reviewed-on: https://go-review.googlesource.com/c/159817 Run-TryBot: Dmitri Shuralyov TryBot-Result: Gobot Gobot Reviewed-by: Brad Fitzpatrick --- go/vcs/vcs.go | 9 --------- 1 file changed, 9 deletions(-) diff --git a/go/vcs/vcs.go b/go/vcs/vcs.go index 0451e97b08..6e58ac7491 100644 --- a/go/vcs/vcs.go +++ b/go/vcs/vcs.go @@ -648,15 +648,6 @@ func expand(match map[string]string, s string) string { // vcsPaths lists the known vcs paths. var vcsPaths = []*vcsPath{ - // go.googlesource.com - { - prefix: "go.googlesource.com", - re: `^(?Pgo\.googlesource\.com/[A-Za-z0-9_.\-]+/?)$`, - vcs: "git", - repo: "https://{root}", - check: noVCSSuffix, - }, - // Github { prefix: "github.com/",