config

package
v0.3.5 Latest Latest
Warning

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

Go to latest
Published: May 8, 2026 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BoolVal

func BoolVal(b *bool) bool

Types

type BuildConfig

type BuildConfig struct {
	DitaOT DitaOTConfig `yaml:"dita_ot"`
}

type CodeActionsConfig

type CodeActionsConfig struct {
	CreateMissingFile CreateMissingFileConfig `yaml:"create_missing_file"`
}

type CompletionConfig

type CompletionConfig struct {
	MaxCandidates int `yaml:"max_candidates"`
}

type Config

type Config struct {
	Core        CoreConfig        `yaml:"core"`
	Completion  CompletionConfig  `yaml:"completion"`
	CodeActions CodeActionsConfig `yaml:"code_actions"`
	Diagnostics DiagnosticsConfig `yaml:"diagnostics"`
	Build       BuildConfig       `yaml:"build"`
}

func Default

func Default() *Config

func Load

func Load(path string) (*Config, error)

func LoadMerged

func LoadMerged(folderRoot string) *Config

func Merge

func Merge(base, overlay *Config) *Config

func Parse

func Parse(data []byte) (*Config, error)

type CoreConfig

type CoreConfig struct {
	Markdown MarkdownConfig `yaml:"markdown"`
	Mdita    MditaConfig    `yaml:"mdita"`
}

type CreateMissingFileConfig

type CreateMissingFileConfig struct {
	Enable *bool `yaml:"enable"`
}

type DiagnosticsConfig

type DiagnosticsConfig struct {
	MditaCompliance   *bool `yaml:"mdita_compliance"`
	DitamapValidation *bool `yaml:"ditamap_validation"`
	KeyrefResolution  *bool `yaml:"keyref_resolution"`
	LinkValidation    *bool `yaml:"link_validation"`
	NbspDetection     *bool `yaml:"nbsp_detection"`
}

type DitaOTConfig

type DitaOTConfig struct {
	Enable    *bool  `yaml:"enable"`
	DitaPath  string `yaml:"dita_path,omitempty"`
	OutputDir string `yaml:"output_dir,omitempty"`
}

type MarkdownConfig

type MarkdownConfig struct {
	FileExtensions   []string `yaml:"file_extensions"`
	TextSync         string   `yaml:"text_sync"`
	TitleFromHeading bool     `yaml:"title_from_heading"`
}

type MditaConfig

type MditaConfig struct {
	Enable        *bool    `yaml:"enable"`
	MapExtensions []string `yaml:"map_extensions"`
}

Jump to

Keyboard shortcuts

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