bufmoduleconfig

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Apr 15, 2024 License: Apache-2.0 Imports: 8 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	// RootToExcludes contains a map from root to the excludes for that root.
	//
	// Roots are the root directories within a bucket to search for Protobuf files.
	//
	// There will be no between the roots, ie foo/bar and foo are not allowed.
	// All Protobuf files must be unique relative to the roots, ie if foo and bar
	// are roots, then foo/baz.proto and bar/baz.proto are not allowed.
	//
	// All roots will be normalized and validated.
	//
	// Excludes are the directories within a bucket to exclude.
	//
	// There should be no overlap between the excludes, ie foo/bar and foo are not allowed.
	//
	// All excludes must reside within a root, but none will be equal to a root.
	// All excludes will be normalized and validated.
	// The excludes in this map will be relative to the root they map to!
	//
	// If RootToExcludes is empty, the default is "." with no excludes.
	RootToExcludes             map[string][]string
	DependencyModuleReferences []bufmoduleref.ModuleReference
}

Config is a configuration for build.

func NewConfigV1

func NewConfigV1(externalConfig ExternalConfigV1, deps ...string) (*Config, error)

NewConfigV1 returns a new, validated Config for the ExternalConfig.

func NewConfigV1Beta1

func NewConfigV1Beta1(externalConfig ExternalConfigV1Beta1, deps ...string) (*Config, error)

NewConfigV1Beta1 returns a new, validated Config for the ExternalConfig.

type ExternalConfigV1

type ExternalConfigV1 struct {
	Excludes []string `json:"excludes,omitempty" yaml:"excludes,omitempty"`
}

ExternalConfigV1 is an external config.

type ExternalConfigV1Beta1

type ExternalConfigV1Beta1 struct {
	Roots    []string `json:"roots,omitempty" yaml:"roots,omitempty"`
	Excludes []string `json:"excludes,omitempty" yaml:"excludes,omitempty"`
}

ExternalConfigV1Beta1 is an external config.

Jump to

Keyboard shortcuts

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