Documentation ¶
Overview ¶
Package config provides specific directories for Heb12 with the apppaths module
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var DataDirs = struct { Bibles string Gratis string Sword string }{ "bibles", "bibles/gratis", "bibles/sword", }
DataDirs contains the directories in which different data is stored
View Source
var DataFiles = struct { Highlights string Bookmarks string }{ "highlights.json", "bookmarks.json", }
DataFiles contains the different files in the data dir that have im
Functions ¶
func InitDirs ¶
func InitDirs() error
InitDirs makes all of the directories required for storing data and configuration
func WriteConfig ¶
Write config writes config information to the config file
Types ¶
type Config ¶
type Config struct {
GUI ConfigGUI `json:"gui"`
}
Config contains all the configuration needed for all apps
func ReadConfig ¶
ReadConfig reads the config file and marshals it into a Config
type ConfigGUI ¶
type ConfigGUI struct { // Locale is localization code currently being used Locale string `json:"locale"` // Book is the ID of the last book loaded Book string `json:"book"` // Chapter is the last chapter of the last book loaded Chapter int `json:"chapter"` // Translation is the translation code of the last translation loaded Translation string `json:"translation"` // Theme is the color theme chosen Theme string `json:"theme"` Font Font `json:"font"` }
ConfigGUI contains all the data stored in the config file for GUI apps
Click to show internal directories.
Click to hide internal directories.