Documentation
¶
Overview ¶
Package jsonfile is for interacting with a JSON file on disk.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type JSONFile ¶
JSONFile representation of a json file.
func LoadFromDisk ¶
LoadFromDisk loads the config.json from disk.
func (*JSONFile) Clear ¶
func (j *JSONFile) Clear()
Clear the contents of the file, setting it to an empty json object.
func (JSONFile) EnsureExists ¶
func (j JSONFile) EnsureExists()
EnsureExists makes sure the file exists on disk, will be empty json if created.
func (JSONFile) PrettyPrint ¶
func (j JSONFile) PrettyPrint()
PrettyPrint outputs the current config as a pretty string.
func (JSONFile) WriteToDisk ¶
func (j JSONFile) WriteToDisk()
WriteToDisk writers the config to disk.
Click to show internal directories.
Click to hide internal directories.