utils

package
v0.9.8 Latest Latest
Warning

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

Go to latest
Published: Apr 17, 2023 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GitClone

func GitClone(repo *Repository, targetDir string) error

func GitPull added in v0.6.1

func GitPull(localDir string) error

func LookupInt added in v0.6.1

func LookupInt(key string, fallback int) int

func Max

func Max(a, b int) int

func Min

func Min(a, b int) int

Types

type GithubRepo added in v0.6.1

type GithubRepo struct {
	Name            string
	FullName        string `json:"full_name"`
	Description     string
	HtmlUrl         string `json:"html_url"`
	StargazersCount int    `json:"stargazers_count"`
}

func SearchSunbeamExtensions added in v0.6.1

func SearchSunbeamExtensions(query string) ([]GithubRepo, error)

type Release added in v0.9.0

type Release struct {
	TagName string `json:"tag_name"`
}

func GetLatestRelease added in v0.9.0

func GetLatestRelease(repo *Repository) (*Release, error)

type Repository

type Repository struct {
	// contains filtered or unexported fields
}

func NewRepository added in v0.6.1

func NewRepository(url *url.URL) *Repository

func RepositoryFromString added in v0.6.1

func RepositoryFromString(pattern string) (*Repository, error)

func (*Repository) FullName

func (r *Repository) FullName() string

func (*Repository) Name

func (r *Repository) Name() string

func (*Repository) Owner

func (r *Repository) Owner() string

func (*Repository) String added in v0.9.0

func (r *Repository) String() string

func (*Repository) Url

func (r *Repository) Url() *url.URL

type SearchBody added in v0.6.1

type SearchBody struct {
	Items []GithubRepo
}

Jump to

Keyboard shortcuts

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