func (g *CommitsService) List(revision string) ([]string, error) {
	if revision == "" {
		return []string{}, errors.New("no revision specified")
	}
	var s []string
	commits, _, err := g.client.API.RepositoriesListCommits(
		context.Background(),
		&github.CommitsListOptions{SHA: revision},
	)
	if err != nil {
		return s, err
	}
	for _, commit := range commits {
		s = append(s, *commit.SHA)
	}
	return s, nil
}
List lists commits on a repository
package github
import (
	"context"
	"errors"
	"strconv"
	"strings"
	"github.com/google/go-github/github"
)
type CommitsService service