stores

package
v0.2.2 Latest Latest
Warning

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

Go to latest
Published: Nov 16, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FetchCharmInfo

func FetchCharmInfo(name string) (*artifactInfoResult, error)

FetchCharmInfo fetches the Json representing charm information by querying the Charmhub API

func FetchSnapInfo

func FetchSnapInfo(name string) (*artifactInfoResult, error)

FetchSnapInfo fetches the Json representing charm information by querying the Snapcraft API

func GetCharmName

func GetCharmName(readme string) (name string)

GetCharmName parses a charm name from a Charmhub badge in repo's README

func GetSnapName

func GetSnapName(readme string) (name string)

GetSnapName tries to parse a snap name from a Snapcraft badge in repo's README

Types

type StoreArtifact

type StoreArtifact struct {
	Name     string          `json:"name"`
	Url      string          `json:"url"`
	Releases []*storeRelease `json:"releases"`
	Channels []string        `json:"channels"`
	Tracks   []string        `json:"tracks"`
}

StoreArtifact holds information about an artifact in a Canonical store (e.g. a snap or charm)

func NewStoreArtifact

func NewStoreArtifact(name string, r *artifactInfoResult) *StoreArtifact

Jump to

Keyboard shortcuts

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