Documentation
¶
Overview ¶
Package github files a publication into a GitHub repository: the RFC as an issue, each child as a sub-issue of it, and each depends_on edge as a "blocked by" relation, the way hive's hive-open-issue does.
Index ¶
Constants ¶
const DefaultAPI = "https://api.github.com"
DefaultAPI is GitHub's REST endpoint; tests point the client elsewhere.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Target ¶
type Target struct {
Owner string
Repo string
// API is the REST base URL, DefaultAPI unless set.
API string
Token string
// HTTPClient defaults to one with requestTimeout.
HTTPClient *http.Client
// UserAgent identifies the client; GitHub requires one.
UserAgent string
}
Target is the GitHub implementation of publish.Target for one repo.
func (*Target) Publish ¶
func (t *Target) Publish(ctx context.Context, p publish.Publication, existing *publish.Existing, opts publish.PublishOptions) (publish.Result, error)
Publish implements publish.Target. Creation order: the RFC first (its URL goes into every child's marker), then the children, then the relations, then the RFC body again with the children's numbers in its checklist. Relations are best effort: a failure becomes a warning, never an error, because the issues exist and a re-run with --update repairs them.
Directories
¶
| Path | Synopsis |
|---|---|
|
Package githubtest is a fake GitHub REST API for tests of the publish github target and of the publish command.
|
Package githubtest is a fake GitHub REST API for tests of the publish github target and of the publish command. |