config

package
v1.0.2 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const (
	ConfigFileName      = ".direnv.toml"
	LocalConfigFileName = ".direnv.local.toml"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	AutoApply   bool              `toml:"auto_apply"`
	Environment map[string]string `toml:"environment"`
	Aliases     map[string]string `toml:"aliases"`
	Scripts     map[string]string `toml:"scripts"`
	Hooks       Hooks             `toml:"hooks"`
}

func FindConfig

func FindConfig(startDir string) (*Config, string, error)

func LoadConfig

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

func MergeConfigs

func MergeConfigs(base, override *Config) *Config

type Hooks

type Hooks struct {
	PreApply  string `toml:"pre_apply"`
	PostApply string `toml:"post_apply"`
	OnLeave   string `toml:"on_leave"`
}

Jump to

Keyboard shortcuts

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