repository

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Dec 30, 2021 License: MPL-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddRepository

func AddRepository(ctx context.Context, url string) error

Types

type Manifest

type Manifest struct {
	BinaryDownloadURLPattern string `json:"binary_download_url_pattern"`

	// Version are sorted descending.
	Versions []Version `json:"versions"`
}

func GetManifest

func GetManifest(ctx context.Context, url string) (Manifest, error)

func (*Manifest) GetBinaryDownloadURL

func (m *Manifest) GetBinaryDownloadURL(version *semver.Version) string

type Plugin

type Plugin struct {
	Name string `json:"name"`

	// Description is a *short* description of the plugin.
	Description  string `json:"description"`
	Website      string `json:"website"`
	ContactEmail string `json:"contact_email"`
	License      string `json:"license"`
	ReadmeURL    string `json:"readme_url"`
	ManifestURL  string `json:"manifest_url"`
}

type Repository

type Repository struct {
	Name        string   `json:"name"`
	Description string   `json:"description"`
	Slug        string   `json:"slug"`
	Plugins     []Plugin `json:"plugins"`
}

func GetRepositories

func GetRepositories(ctx context.Context) ([]Repository, error)

func GetRepository

func GetRepository(ctx context.Context, url string) (Repository, error)

type RepositoryEntry

type RepositoryEntry struct {
	URL string `json:"url"`
}

type Version

type Version struct {
	Number *semver.Version `json:"number"`
}

Jump to

Keyboard shortcuts

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