bazaar

package
v0.0.0-...-7d34a87 Latest Latest
Warning

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

Go to latest
Published: Dec 18, 2024 License: AGPL-3.0 Imports: 24 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CleanBazaarPackageCache

func CleanBazaarPackageCache()

func GetPackageREADME

func GetPackageREADME(repoURL, repoHash, packageType string) (ret string)

func GetPreferredName

func GetPreferredName(pkg *Package) string

func InstallIcon

func InstallIcon(repoURL, repoHash, installPath string, systemID string) error

func InstallPlugin

func InstallPlugin(repoURL, repoHash, installPath string, systemID string) error

func InstallTemplate

func InstallTemplate(repoURL, repoHash, installPath string, systemID string) error

func InstallTheme

func InstallTheme(repoURL, repoHash, installPath string, systemID string) error

func InstallWidget

func InstallWidget(repoURL, repoHash, installPath string, systemID string) error

func ParseInstalledPlugin

func ParseInstalledPlugin(name, frontend string) (found bool, displayName string, incompatible bool)

func UninstallIcon

func UninstallIcon(installPath string) error

func UninstallPlugin

func UninstallPlugin(installPath string) error

func UninstallTemplate

func UninstallTemplate(installPath string) error

func UninstallTheme

func UninstallTheme(installPath string) error

func UninstallWidget

func UninstallWidget(installPath string) error

Types

type Description

type Description struct {
	Default string `json:"default"`
	DeDE    string `json:"de_DE"`
	EnUS    string `json:"en_US"`
	EsES    string `json:"es_ES"`
	FrFR    string `json:"fr_FR"`
	HeIL    string `json:"he_IL"`
	ItIT    string `json:"it_IT"`
	JaJP    string `json:"ja_JP"`
	PlPL    string `json:"pl_PL"`
	RuRU    string `json:"ru_RU"`
	ZhCHT   string `json:"zh_CHT"`
	ZhCN    string `json:"zh_CN"`
}

type DisplayName

type DisplayName struct {
	Default string `json:"default"`
	DeDE    string `json:"de_DE"`
	EnUS    string `json:"en_US"`
	EsES    string `json:"es_ES"`
	FrFR    string `json:"fr_FR"`
	HeIL    string `json:"he_IL"`
	ItIT    string `json:"it_IT"`
	JaJP    string `json:"ja_JP"`
	PlPL    string `json:"pl_PL"`
	RuRU    string `json:"ru_RU"`
	ZhCHT   string `json:"zh_CHT"`
	ZhCN    string `json:"zh_CN"`
}

type Funding

type Funding struct {
	OpenCollective string   `json:"openCollective"`
	Patreon        string   `json:"patreon"`
	GitHub         string   `json:"github"`
	Custom         []string `json:"custom"`
}

type Icon

type Icon struct {
	*Package
}

func IconJSON

func IconJSON(iconDirName string) (ret *Icon, err error)

func Icons

func Icons() (icons []*Icon)

func InstalledIcons

func InstalledIcons() (ret []*Icon)

type Package

type Package struct {
	Author        string       `json:"author"`
	URL           string       `json:"url"`
	Version       string       `json:"version"`
	MinAppVersion string       `json:"minAppVersion"`
	Backends      []string     `json:"backends"`
	Frontends     []string     `json:"frontends"`
	DisplayName   *DisplayName `json:"displayName"`
	Description   *Description `json:"description"`
	Readme        *Readme      `json:"readme"`
	Funding       *Funding     `json:"funding"`
	Keywords      []string     `json:"keywords"`

	PreferredFunding string `json:"preferredFunding"`
	PreferredName    string `json:"preferredName"`
	PreferredDesc    string `json:"preferredDesc"`
	PreferredReadme  string `json:"preferredReadme"`

	Name            string `json:"name"`
	RepoURL         string `json:"repoURL"`
	RepoHash        string `json:"repoHash"`
	PreviewURL      string `json:"previewURL"`
	PreviewURLThumb string `json:"previewURLThumb"`
	IconURL         string `json:"iconURL"`

	Installed    bool   `json:"installed"`
	Outdated     bool   `json:"outdated"`
	Current      bool   `json:"current"`
	Updated      string `json:"updated"`
	Stars        int    `json:"stars"`
	OpenIssues   int    `json:"openIssues"`
	Size         int64  `json:"size"`
	HSize        string `json:"hSize"`
	InstallSize  int64  `json:"installSize"`
	HInstallSize string `json:"hInstallSize"`
	HInstallDate string `json:"hInstallDate"`
	HUpdated     string `json:"hUpdated"`
	Downloads    int    `json:"downloads"`

	Incompatible bool `json:"incompatible"`
}

type Plugin

type Plugin struct {
	*Package
	Enabled bool `json:"enabled"`
}

func InstalledPlugins

func InstalledPlugins(frontend string, checkUpdate bool) (ret []*Plugin)

func PluginJSON

func PluginJSON(pluginDirName string) (ret *Plugin, err error)

func Plugins

func Plugins(frontend string) (plugins []*Plugin)

type Readme

type Readme struct {
	Default string `json:"default"`
	DeDE    string `json:"de_DE"`
	EnUS    string `json:"en_US"`
	EsES    string `json:"es_ES"`
	FrFR    string `json:"fr_FR"`
	HeIL    string `json:"he_IL"`
	ItIT    string `json:"it_IT"`
	JaJP    string `json:"ja_JP"`
	PlPL    string `json:"pl_PL"`
	RuRU    string `json:"ru_RU"`
	ZhCHT   string `json:"zh_CHT"`
	ZhCN    string `json:"zh_CN"`
}

type StageIndex

type StageIndex struct {
	Repos []*StageRepo `json:"repos"`
}

type StagePackage

type StagePackage struct {
	Author      string       `json:"author"`
	URL         string       `json:"url"`
	Version     string       `json:"version"`
	Description *Description `json:"description"`
	Readme      *Readme      `json:"readme"`
	I18N        []string     `json:"i18n"`
	Funding     *Funding     `json:"funding"`
}

type StageRepo

type StageRepo struct {
	URL         string `json:"url"`
	Updated     string `json:"updated"`
	Stars       int    `json:"stars"`
	OpenIssues  int    `json:"openIssues"`
	Size        int64  `json:"size"`
	InstallSize int64  `json:"installSize"`

	Package *StagePackage `json:"package"`
}

type Template

type Template struct {
	*Package
}

func InstalledTemplates

func InstalledTemplates() (ret []*Template)

func TemplateJSON

func TemplateJSON(templateDirName string) (ret *Template, err error)

func Templates

func Templates() (templates []*Template)

type Theme

type Theme struct {
	*Package

	Modes []string `json:"modes"`
}

func InstalledThemes

func InstalledThemes() (ret []*Theme)

func ThemeJSON

func ThemeJSON(themeDirName string) (ret *Theme, err error)

func Themes

func Themes() (ret []*Theme)

type Widget

type Widget struct {
	*Package
}

func InstalledWidgets

func InstalledWidgets() (ret []*Widget)

func WidgetJSON

func WidgetJSON(widgetDirName string) (ret *Widget, err error)

func Widgets

func Widgets() (widgets []*Widget)

Jump to

Keyboard shortcuts

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