config

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: May 29, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	ImportPaths          []string             `toml:"import"`
	DefaultSessionConfig DefaultSessionConfig `toml:"default_session"`
	SessionConfigs       []SessionConfig      `toml:"session"`
}

func ParseConfigFile

func ParseConfigFile(fetcher ConfigDirectoryFetcher) Config

TODO: add error handling (return error)

type ConfigDirectoryFetcher added in v1.0.0

type ConfigDirectoryFetcher interface {
	GetUserConfigDir() (string, error)
}

type DefaultConfigDirectoryFetcher added in v1.0.0

type DefaultConfigDirectoryFetcher struct{}

func (*DefaultConfigDirectoryFetcher) GetUserConfigDir added in v1.0.0

func (d *DefaultConfigDirectoryFetcher) GetUserConfigDir() (string, error)

type DefaultSessionConfig added in v1.0.0

type DefaultSessionConfig struct {
	StartupScript  string `toml:"startup_script"`
	StartupCommand string `toml:"startup_command"`
	Tmuxp          string `toml:"tmuxp"`
	Tmuxinator     string `toml:"tmuxinator"`
}

type SessionConfig added in v1.0.0

type SessionConfig struct {
	Name string `toml:"name"`
	Path string `toml:"path"`
	DefaultSessionConfig
}

Jump to

Keyboard shortcuts

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