config

package
v0.0.0-...-545aef7 Latest Latest
Warning

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

Go to latest
Published: Oct 15, 2020 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ConfigFileName = "kableconfig.json"
)

Variables

View Source
var CacheDir string
View Source
var ConceptDir string
View Source
var ConfigPath string
View Source
var CurDir string
View Source
var RepoDir string
View Source
var RootDir string
View Source
var UserDir string

Functions

func ReadConfig

func ReadConfig(cfgFile string) (string, error)

ReadConfig tries to read Config from either a file at the path that has been given as string argument, or, if cfgFile is an empty string, tries default locations.

Default: /etc/kable/kableconfig.json, ~/.kable/kableconfig.json, ./kableconfig.json

Types

type Config

type Config struct {
	APIVersion          int  `json:"apiVersion"`
	UseKeychainProvider bool `json:"useKeychainProvider"`
}

Config represents the Kable currentConfig object

func GetConfig

func GetConfig() (*Config, error)

GetConfig returns the current Config Object. One first needs to Read or Init Config.

Jump to

Keyboard shortcuts

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