config

package
v0.0.0-...-8fec888 Latest Latest
Warning

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

Go to latest
Published: Aug 7, 2023 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const LogToStderr = "--use-stderr"

Variables

This section is empty.

Functions

func DefaultConfigPath

func DefaultConfigPath() (string, error)

Types

type Config

type Config struct {
	// path to executables
	FzfPath string `json:"fzf-path"`

	// path to use for a log file
	LogFile string `json:"log-file"`

	// Name of the remote to use
	Selected string `json:"selected-remote"`
	// configs for all defined remote
	Remotes map[string]map[string]any `json:"remotes-configs"`

	// Providers in the blacklist will not be used
	Blacklist []string `json:"providers-blacklist"`
	// configs for all defined provider
	Providers map[string]map[string]any `json:"providers-config"`

	// path to the config file: not saved
	ConfigFile string `json:"-"`
}

func LoadConfig

func LoadConfig() (*Config, error)

func LoadConfigAt

func LoadConfigAt(configFile string) (*Config, error)

func (*Config) Save

func (c *Config) Save() error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
JackTT - Gopher 🇻🇳