Documentation ¶
Overview ¶
Package checkout supports checking out git repositories for testing during Buildbucket builds.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Checkout ¶
func Checkout(ctx context.Context, input *buildbucketpb.Build_Input, repoURL url.URL, defaultRevision, dir string) error
Checkout checks out the git repo at repoURL according to the given build input.
defaultRevision specifies the revision to check out if the build was triggered by a commit or change on a *different* repository, in which case we can't use the build input to determine which revision of `repoURL` to check out.
func GitilesChangeRef ¶
func GitilesChangeRef(change *buildbucketpb.GerritChange) string
Returns the Gitiles ref for a gerrit changeNumber. The ref has the form xx/yyyy/zz where xx is `yyyy modulo 100` (always 2 digits), and zz is the patchset number.
func RemoveCodeReviewSuffix ¶
Converts foo-review.googlesource.com to foo.googlesource.com
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.