config

package
v0.24.3 Latest Latest
Warning

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

Go to latest
Published: May 7, 2024 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const DevModeMwdd string = "docker"

DevModeMwdd value for DevMode that will use the docker/mediawiki-docker-dev command set.

Variables

View Source
var DevModeValues = AllowedOptions([]string{DevModeMwdd})

DevModeValues allowed values for DevMode.

Functions

func Path added in v0.14.0

func Path() string

Path path of the config file.

Types

type AllowedOptions

type AllowedOptions []string

AllowedOptions representation of allowed options for a config value.

func (AllowedOptions) Contains

func (cao AllowedOptions) Contains(value string) bool

Contains do the allowed options contain this value.

type Config

type Config struct {
	DevMode                string `json:"dev_mode"`
	Telemetry              string `json:"telemetry"`
	TimerLastEmittedEvent  string `json:"_timer_last_emitted_event"`
	TimerLastUpdateChecked string `json:"_timer_last_update_checked"`
}

Config representation of a cli config.

func LoadFromDisk

func LoadFromDisk() Config

LoadFromDisk loads the config.json from disk.

func (Config) PrettyPrint

func (c Config) PrettyPrint()

PrettyPrint writes the config to disk.

func (Config) WriteToDisk

func (c Config) WriteToDisk()

WriteToDisk writers the config to disk.

Jump to

Keyboard shortcuts

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