Documentation ¶
Index ¶
- Constants
- func AllSettings() map[string]interface{}
- func AppendRecentEntry(file string) error
- func BuildCommit() string
- func BuildDate() string
- func BuildVersion() string
- func ConfigDir() string
- func ConfigFileUsed() string
- func EditorCommand() string
- func Get(key string) any
- func GetString(key string) string
- func IsSet(key string) bool
- func NewConfig(cfgDir string) *viper.Viper
- func RecentEntries() []string
- func RegistryCachePath() string
- func RegistryDir() string
- func RegistryUrl() string
- func RemoveRecentEntry(d string) error
- func ServerPort() string
- func Set(key string, value any)
- func SetBuildInfo(version, commit, date string)
- func SetConfig(c *viper.Viper)
- func TemplateCacheDir() string
- func UpdateChannel() string
- func WriteConfig() error
Constants ¶
View Source
const ( KeyRecent = "recent" KeyServerPort = "server_port" KeyEditorCommand = "editor_command" KeyUpdateChannel = "update_channel" KeyTemplatesDir = "templates_dir" KeyRegistryDir = "registry_dir" KeyRegistryUrl = "registry_url" KeyVersion = "version" KeyCommit = "commit" KeyDate = "date" )
Variables ¶
This section is empty.
Functions ¶
func AllSettings ¶
func AllSettings() map[string]interface{}
func AppendRecentEntry ¶
AppendRecentEntry appends a new entry to the list of recent entries entries are limited to 5 the most recent entry is at the beginning of the list stores the list in the config file
func BuildCommit ¶
func BuildCommit() string
func BuildVersion ¶
func BuildVersion() string
func ConfigFileUsed ¶
func ConfigFileUsed() string
func EditorCommand ¶
func EditorCommand() string
func RegistryCachePath ¶
func RegistryCachePath() string
func RegistryDir ¶
func RegistryDir() string
func RegistryUrl ¶
func RegistryUrl() string
func RemoveRecentEntry ¶
RemoveRecentEntry removes a recent entry from the list
func ServerPort ¶
func ServerPort() string
func SetBuildInfo ¶
func SetBuildInfo(version, commit, date string)
func TemplateCacheDir ¶
func TemplateCacheDir() string
func UpdateChannel ¶
func UpdateChannel() string
func WriteConfig ¶
func WriteConfig() error
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.