util

package
v0.3.10 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FlagsValuesUsage

func FlagsValuesUsage(prefix string, candidates interface{}) string

func GenerateRandomStr added in v0.3.4

func GenerateRandomStr(length int) string

func HttpGet added in v0.2.0

func HttpGet(url string) (string, *http.Response, error)

func NewLogWriter

func NewLogWriter(log *logrus.Entry, level logrus.Level, prefix string) io.Writer

func UpdateCommandDefaultLog

func UpdateCommandDefaultLog(cmd *exec.Cmd, logLevel logrus.Level) *exec.Cmd

func UpdateCommandDefaultLogWithInfo

func UpdateCommandDefaultLogWithInfo(cmd *exec.Cmd) *exec.Cmd

Types

type GithubInfoer added in v0.2.0

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

func NewGithubInfoer added in v0.2.0

func NewGithubInfoer(token string) *GithubInfoer

func (*GithubInfoer) GetLatestVersion added in v0.2.0

func (g *GithubInfoer) GetLatestVersion(repoOwner string, repo string) (*data.Version, error)

func (*GithubInfoer) GetVersionsAfterVersion added in v0.2.0

func (g *GithubInfoer) GetVersionsAfterVersion(afterVersion data.Version, repoOwner string, repo string, minorVersionCount int) ([]*data.Version, error)

type LogWriter

type LogWriter struct {
	Log *logrus.Entry
	// contains filtered or unexported fields
}

func (LogWriter) Write

func (l LogWriter) Write(p []byte) (n int, err error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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