utils

package
v0.0.22 Latest Latest
Warning

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

Go to latest
Published: Jul 3, 2025 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConvertAirToml

func ConvertAirToml(inputPath string) error

Types

type AirConfig

type AirConfig struct {
	Root   string      `toml:"root"`
	TmpDir string      `toml:"tmp_dir"`
	Build  BuildConfig `toml:"build"`
	Log    LogConfig   `toml:"log"`
	Misc   MiscConfig  `toml:"misc"`
	Color  ColorConfig `toml:"color"`
}

AirConfig represents the structure of a .air.toml file.

type BuildConfig

type BuildConfig struct {
	Cmd          string   `toml:"cmd"`
	Bin          string   `toml:"bin"`
	PreCmd       []string `toml:"pre_cmd"`
	PostCmd      []string `toml:"post_cmd"`
	IncludeExt   []string `toml:"include_ext"`
	ExcludeDir   []string `toml:"exclude_dir"`
	ExcludeFile  []string `toml:"exclude_file"`
	IncludeDir   []string `toml:"include_dir"`
	ExcludeRegex []string `toml:"exclude_regex"`
	StopOnError  bool     `toml:"stop_on_error"`
	Delay        int      `toml:"delay"`
}

type ColorConfig

type ColorConfig struct {
	Main    string `toml:"main"`
	Watcher string `toml:"watcher"`
	Build   string `toml:"build"`
	Runner  string `toml:"runner"`
}

type LogConfig

type LogConfig struct {
	LogName        string `toml:"log_name"`
	RedirectOutput bool   `toml:"redirect_output"`
}

type MiscConfig

type MiscConfig struct {
	CleanOnExit bool `toml:"clean_on_exit"`
}

Jump to

Keyboard shortcuts

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