Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ParseURL ¶ added in v0.5.0
ParseURL validates the shared user-attachment URL format, without choosing an authentication host.
func PrewarmUploadHostDNS ¶ added in v0.4.3
PrewarmUploadHostDNS resolves upload-host DNS in the background, DNS-only.
func StatUploadFile ¶ added in v0.5.0
StatUploadFile rejects inputs that cannot be streamed as regular files.
func SupportsTokenUpload ¶ added in v0.5.0
Types ¶
type RefererPage ¶
type RefererPage struct {
URL string
Meta refererPageMetadata
}
RefererPage carries the referer URL and the metadata parsed from its HTML at fetch time.
type RefererPageFetcher ¶
type RefererPageFetcher interface {
Fetch(ctx context.Context, client *web.Client) (*RefererPage, error)
}
func NewCommitHeadPageFetcher ¶
func NewCommitHeadPageFetcher(host string, repoFullName string) RefererPageFetcher
func NewIssueNewPageFetcher ¶
func NewIssueNewPageFetcher(host string, repoFullName string) RefererPageFetcher
type TokenUploader ¶ added in v0.5.0
type TokenUploader struct {
// contains filtered or unexported fields
}
TokenUploader sends media to GitHub Cloud using gh API authentication.
func NewTokenUploader ¶ added in v0.5.0
type Uploader ¶
type Uploader struct {
// contains filtered or unexported fields
}
Uploader carries the shared session context for GitHub user-attachment uploads.
func NewUploader ¶
func (*Uploader) ResolveRefererPage ¶
func (u *Uploader) ResolveRefererPage(ctx context.Context, fetchers []RefererPageFetcher) (*RefererPage, error)