Documentation
¶
Index ¶
- func AddGameSetup(setup GameSetup) error
- func GetConfigPath() (string, error)
- func GetGameLogDirectory() (string, error)
- func GetImageCacheEnabled() (bool, error)
- func GetSteamGridDBAPIKey() (string, error)
- func RemoveGameSetup(id string) error
- func Save(config *AppConfig) error
- func SetGameLogDirectory(dir string) error
- func SetImageCacheEnabled(enabled bool) error
- func SetSteamGridDBAPIKey(apiKey string) error
- func UpdateGameSetup(id string, setup GameSetup) error
- type AppConfig
- type GameSetup
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddGameSetup ¶
AddGameSetup adds a game setup to the config
func GetConfigPath ¶
GetConfigPath returns the path to the config file
func GetGameLogDirectory ¶ added in v0.6.0
GetGameLogDirectory returns the directory for game log files
func GetImageCacheEnabled ¶
GetImageCacheEnabled returns whether image caching is enabled
func GetSteamGridDBAPIKey ¶
GetSteamGridDBAPIKey returns the SteamGridDB API key
func RemoveGameSetup ¶
RemoveGameSetup removes a game setup from the config
func SetGameLogDirectory ¶ added in v0.6.0
SetGameLogDirectory sets the directory for game log files
func SetImageCacheEnabled ¶
SetImageCacheEnabled enables or disables image caching
func SetSteamGridDBAPIKey ¶
SetSteamGridDBAPIKey saves the SteamGridDB API key
func UpdateGameSetup ¶
UpdateGameSetup updates an existing game setup
Types ¶
type AppConfig ¶
type AppConfig struct {
GameSetups []GameSetup `json:"game_setups"`
SteamGridDBAPIKey string `json:"steamgriddb_api_key,omitempty"`
ImageCacheEnabled bool `json:"image_cache_enabled"`
GameLogDirectory string `json:"game_log_directory,omitempty"`
}
AppConfig represents the application configuration
type GameSetup ¶
type GameSetup struct {
ID string `json:"id"`
Name string `json:"name"`
LocalPath string `json:"local_path"`
Executable string `json:"executable"`
LaunchOptions string `json:"launch_options,omitempty"`
Tags string `json:"tags,omitempty"`
InstallPath string `json:"install_path"`
// SteamGridDB artwork
GridDBGameID int `json:"griddb_game_id,omitempty"`
GridPortrait string `json:"grid_portrait,omitempty"` // 600x900 portrait grid
GridLandscape string `json:"grid_landscape,omitempty"` // 920x430 landscape grid
HeroImage string `json:"hero_image,omitempty"` // 1920x620 hero banner
LogoImage string `json:"logo_image,omitempty"` // Logo with transparency
IconImage string `json:"icon_image,omitempty"` // Square icon
}
GameSetup represents a saved game installation setup
func GetGameSetups ¶
GetGameSetups returns all saved game setups