source

package
v0.6.2 Latest Latest
Warning

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

Go to latest
Published: Nov 24, 2024 License: AGPL-3.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ID

type ID string

A unique identifier for a source

func NewGitHubID

func NewGitHubID(owner, repo, path string) ID

func NewIDFromChangelog

func NewIDFromChangelog(cl store.Changelog) ID

func NewLocalID

func NewLocalID(path string) ID

func (ID) String

func (i ID) String() string

type LoadResult

type LoadResult struct {
	Raw     []RawReleaseNote
	HasMore bool
}

func (LoadResult) HasChanged

func (r LoadResult) HasChanged() bool

Returns if any of the loaded release notes have changed since last access.

type RawReleaseNote

type RawReleaseNote struct {
	Content io.Reader
	// contains filtered or unexported fields
}

type Source

type Source interface {
	Load(ctx context.Context, page internal.Pagination) (LoadResult, error)
	ID() ID
}

A source can be used to load raw release notes from a (remote) source like GitHub.

func NewGHSourceFromStore

func NewGHSourceFromStore(cfg config.Config, gh store.GHSource, cache xcache.Cache) (Source, error)

func NewLocalSourceFromStore

func NewLocalSourceFromStore(s store.LocalSource, cache xcache.Cache) Source

func NewSourceFromStore

func NewSourceFromStore(cfg config.Config, cl store.Changelog, cache xcache.Cache) (Source, error)

Jump to

Keyboard shortcuts

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