repository

package
v0.9.4 Latest Latest
Warning

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

Go to latest
Published: Sep 4, 2022 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"`

	// FileExtensions supported by the plugin.
	FileExtensions []string `json:"file_extensions"`
	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