Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GHLoader ¶
type GHLoader struct { Owner string Repo string Path string InstallationID int64 // contains filtered or unexported fields }
func (GHLoader) Load ¶
func (s GHLoader) Load(ctx context.Context, params Pagination) (LoadResult, error)
type GithubLoaderOptions ¶
type GithubLoaderOptions struct { // The account name of the owner of the repository Owner string // The repository which holds the markdown files Repository string // The path to the root of the directory which holds all markdown files Path string AppPrivateKey string AppInstallationId int64 AccessToken string }
type LoadResult ¶
type LoadResult struct { Articles []RawArticle HasMore bool }
type Loader ¶
type Loader interface {
Load(ctx context.Context, page Pagination) (LoadResult, error)
}
A loader downloads the changelog markdown files.
func NewGithub ¶
func NewGithub(opts GithubLoaderOptions) (Loader, error)
func NewLocalFile ¶
type LocalFileLoader ¶
type LocalFileLoader struct {
// contains filtered or unexported fields
}
func (LocalFileLoader) Load ¶
func (s LocalFileLoader) Load(ctx context.Context, page Pagination) (LoadResult, error)
type Pagination ¶
func NewPagination ¶
func NewPagination(pageSize int, page int) Pagination
type RawArticle ¶
type RawArticle struct {
Content io.ReadCloser
}
Source Files ¶
Click to show internal directories.
Click to hide internal directories.