Documentation
¶
Index ¶
Constants ¶
View Source
const (
PluginConfigPath = "buf.plugin.yaml"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ArchiveConfig ¶
type ArchiveConfig struct {
Deps []struct {
Name string `json:"name" yaml:"name"`
Version string `json:"version" yaml:"version"`
} `json:"deps,omitempty" yaml:"deps,omitempty"`
}
ArchiveConfig is the configuration for a plugin that can be downloaded as an archive instead of a language-specific registry.
type GoConfig ¶
type GoConfig struct {
// The minimum Go version required by the plugin.
MinVersion string `json:"min_version" yaml:"min_version"`
Deps []struct {
Module string `json:"module" yaml:"module"`
Version string `json:"version" yaml:"version"`
} `json:"deps,omitempty" yaml:"deps,omitempty"`
}
GoConfig is the configuration for a Go plugin.
type NPMConfig ¶
type NPMConfig struct {
Deps []struct {
Package string `json:"package" yaml:"package"`
Version string `json:"version" yaml:"version"`
} `json:"deps,omitempty" yaml:"deps,omitempty"`
}
NPMConfig is the configuration for a JavaScript NPM plugin.
type PluginConfig ¶
type PluginConfig struct {
Owner string `json:"owner" yaml:"owner"`
Name string `json:"name" yaml:"name"`
Version string `json:"version" yaml:"version"`
Opts []string `json:"opts,omitempty" yaml:"opts,omitempty"`
Deps []string `json:"deps,omitempty" yaml:"deps,omitempty"`
Runtime Runtime `json:"runtime" yaml:"runtime"`
}
PluginConfig is the config used to describe a plugin.
func ParsePluginConfig ¶
func ParsePluginConfig(config string) (*PluginConfig, error)
ParsePluginConfig parses the file at the given path as a PluginConfig.
type Runtime ¶
type Runtime struct {
Go *GoConfig `json:"go,omitempty" yaml:"go,omitempty"`
NPM *NPMConfig `json:"npm,omitempty" yaml:"npm,omitempty"`
Archive *ArchiveConfig `json:"archive,omitempty" yaml:"archive,omitempty"`
}
Runtime is the configuration for the runtime of a plugin.
Click to show internal directories.
Click to hide internal directories.