config

package
v1.0.0-rc.102 Latest Latest
Warning

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

Go to latest
Published: Dec 13, 2023 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Path string

Functions

This section is empty.

Types

type Config

type Config struct {
	Oneliners  map[string]Oneliner        `json:"oneliners,omitempty"`
	Extensions map[string]ExtensionConfig `json:"extensions,omitempty"`
	// contains filtered or unexported fields
}

func Load

func Load(configPath string) (Config, error)

func (Config) Aliases

func (cfg Config) Aliases() []string

func (Config) Resolve

func (cfg Config) Resolve(path string) string

func (Config) Save

func (c Config) Save() error

type ExtensionConfig

type ExtensionConfig struct {
	Origin      string           `json:"origin,omitempty"`
	Preferences map[string]any   `json:"preferences,omitempty"`
	Root        []types.RootItem `json:"root,omitempty"`
}

type Oneliner

type Oneliner struct {
	Command string `json:"command"`
	Cwd     string `json:"cwd,omitempty"`
	Exit    bool   `json:"exit,omitempty"`
}

Jump to

Keyboard shortcuts

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