Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BuildConfig ¶
type BuildConfig struct {
Workers int `mapstructure:"workers"`
Incremental bool `mapstructure:"incremental"`
Cache CacheConfig `mapstructure:"cache"`
}
BuildConfig contains build settings
type CacheConfig ¶
type CacheConfig struct {
Enabled bool `mapstructure:"enabled"`
Directory string `mapstructure:"directory"`
}
CacheConfig contains cache settings
type Config ¶
type Config struct {
Project ProjectConfig `mapstructure:"project"`
Proto ProtoConfig `mapstructure:"proto"`
Output OutputConfig `mapstructure:"output"`
Languages LanguagesConfig `mapstructure:"languages"`
Build BuildConfig `mapstructure:"build"`
Versioning VersioningConfig `mapstructure:"versioning"`
Logging LoggingConfig `mapstructure:"logging"`
Dependencies []dependency.Dependency `mapstructure:"dependencies"`
Plugins []PluginConfig `mapstructure:"plugins"`
Templates []TemplateConfig `mapstructure:"templates"`
}
Config represents the Buffalo configuration
func LoadFromFile ¶
LoadFromFile loads configuration from a specific file
func (*Config) GetEnabledLanguages ¶
GetEnabledLanguages returns a list of enabled languages
func (*Config) GetOutputDir ¶
GetOutputDir returns the output directory for a specific language
func (*Config) IsLanguageEnabled ¶
IsLanguageEnabled returns whether a language is enabled
type CppConfig ¶
type CppConfig struct {
Enabled bool `mapstructure:"enabled"`
Namespace string `mapstructure:"namespace"`
}
CppConfig contains C++-specific settings
type GoConfig ¶
type GoConfig struct {
Enabled bool `mapstructure:"enabled"`
Module string `mapstructure:"module"`
Generator string `mapstructure:"generator"`
}
GoConfig contains Go-specific settings
type LanguagesConfig ¶
type LanguagesConfig struct {
Python PythonConfig `mapstructure:"python"`
Go GoConfig `mapstructure:"go"`
Rust RustConfig `mapstructure:"rust"`
Cpp CppConfig `mapstructure:"cpp"`
}
LanguagesConfig contains language-specific settings
type LoggingConfig ¶
type LoggingConfig struct {
Level string `mapstructure:"level"`
Format string `mapstructure:"format"`
Output string `mapstructure:"output"`
File string `mapstructure:"file"`
}
LoggingConfig contains logging settings
type OutputConfig ¶
type OutputConfig struct {
BaseDir string `mapstructure:"base_dir"`
Directories map[string]string `mapstructure:"directories"`
PreserveProtoStructure bool `mapstructure:"preserve_proto_structure"`
}
OutputConfig contains output settings
type PluginConfig ¶ added in v1.0.0
type PluginConfig struct {
Name string `mapstructure:"name"`
Enabled bool `mapstructure:"enabled"`
HookPoints []string `mapstructure:"hooks"`
Priority int `mapstructure:"priority"`
Options map[string]interface{} `mapstructure:"config"`
}
PluginConfig contains plugin configuration
type ProjectConfig ¶
type ProjectConfig struct {
Name string `mapstructure:"name"`
Version string `mapstructure:"version"`
}
ProjectConfig contains project-level settings
type ProtoConfig ¶
type ProtoConfig struct {
Paths []string `mapstructure:"paths"`
Exclude []string `mapstructure:"exclude"`
ImportPaths []string `mapstructure:"import_paths"`
}
ProtoConfig contains proto file settings
type PythonConfig ¶
type PythonConfig struct {
Enabled bool `mapstructure:"enabled"`
Package string `mapstructure:"package"`
Generator string `mapstructure:"generator"`
}
PythonConfig contains Python-specific settings
type RustConfig ¶
type RustConfig struct {
Enabled bool `mapstructure:"enabled"`
Generator string `mapstructure:"generator"`
}
RustConfig contains Rust-specific settings
type TemplateConfig ¶ added in v1.0.0
type TemplateConfig struct {
Name string `mapstructure:"name"`
Language string `mapstructure:"language"`
Path string `mapstructure:"path"`
Patterns []string `mapstructure:"patterns"`
Vars map[string]string `mapstructure:"vars"`
}
TemplateConfig contains template configuration
type VersioningConfig ¶
type VersioningConfig struct {
Enabled bool `mapstructure:"enabled"`
Strategy string `mapstructure:"strategy"` // hash, timestamp, semantic, git
OutputFormat string `mapstructure:"output_format"` // directory, suffix
KeepVersions int `mapstructure:"keep_versions"` // 0 = keep all, >0 = keep N latest
}
VersioningConfig contains versioning settings