github

package
v0.0.0-...-070363a Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 4, 2022 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Overview

Package github is a focused wrapper around `github.com/google/go-github` with methods needed for `blend/require-conditional-status-checks`.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetFile

func GetFile(ctx context.Context, c *github.Client, owner, repo, ref, path string) ([]byte, error)

GetFile downloads the contents of a file.

func NewClient

func NewClient(ctx context.Context, rootURL, token string) (*github.Client, error)

NewClient creates a new client and determines if it's needed for the public GitHub API or GitHub Enterprise. The `rootURL` is expected to be the value of the `GITHUB_API_URL` environment variable / the `${{ github.api_url }}` context value.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL