buf

package
v0.8.15 Latest Latest
Warning

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

Go to latest
Published: May 20, 2023 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddArg

func AddArg(arg string) func(*bufArgs)

AddArg adds a simple argument.

func AddPaths

func AddPaths(paths []string) func(*bufArgs)

func Build added in v0.8.4

func Build(binFile string, bufConfigs ...string) error

func BuildDir added in v0.8.6

func BuildDir(dir, binFile string) error

func CreateDevWorkspace added in v0.8.4

func CreateDevWorkspace(protoDirs, dependencies []string) (func() error, error)

func Generate added in v0.8.4

func Generate(binFile string, protoPluginPaths []string) error

Generate proto artifacts

func GenerateDev added in v0.8.4

func GenerateDev(binFile string, protoDirs, deps, protoPluginPaths []string) (err error)

func GetCommonProtoRepo added in v0.8.4

func GetCommonProtoRepo() string

func Lint added in v0.8.4

func Lint(bufConfigs ...string) error

func LintBin added in v0.8.4

func LintBin(binFile string, bufConfigs ...string) error

func ModUpdate added in v0.8.4

func ModUpdate(dirs ...string) error

func Run

func Run(args ...Arg) error

Run runs the protoc CLI

func RunWithEnv added in v0.8.5

func RunWithEnv(env map[string]string, args ...Arg) (err error)

Run runs the protoc CLI with the given environment variables.

func WithLogin added in v0.8.5

func WithLogin() func(*bufArgs)

Types

type Arg

type Arg func(*bufArgs)

Arg represents a protoc CLI argument

type Tag added in v0.4.5

type Tag struct {
	Name        string `json:"name"`
	Commit      string `json:"commit"`
	CreatedTime string `json:"create_time"`
}

func GetLatestTag added in v0.4.5

func GetLatestTag(repository string) (Tag, error)

Gets the latest commit based on create_date

func GetTags added in v0.4.5

func GetTags(repository string) ([]Tag, error)

Gets all the tags from a buf repository

Jump to

Keyboard shortcuts

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