From 7f1f75e43150c97cad36371d2f8ddb76b4a79689 Mon Sep 17 00:00:00 2001 From: Philip Kristoffersen Date: Sat, 25 Sep 2021 13:33:52 +0200 Subject: [PATCH] Update readme --- Readme.md | 45 +++++++++++++++++++++++++++++++++--------- src/defaultconfig.toml | 4 ++++ src/settings.rs | 6 +++--- 3 files changed, 43 insertions(+), 12 deletions(-) diff --git a/Readme.md b/Readme.md index 0e8e28b..914664e 100644 --- a/Readme.md +++ b/Readme.md @@ -2,21 +2,21 @@ ## Description -This little tool will syncrhonize games from other store platforms into your Steam library. +This little tool will synchronize games from other platforms into your Steam library. The goal is that you do not have to leave your Steam library to launch games from other launchers/stores. ## Features -* Add shortcuts to games from [Epic Games Store](https://www.epicgames.com/) (Windows) -* Add shortcuts to games from [Legendary](https://github.com/derrod/legendary) (Linux) +* Add shortcuts to games from [Epic Games Store](https://www.epicgames.com/) +* Add shortcuts to games from [Legendary](https://github.com/derrod/legendary) * Download custom art for games from [SteamGridDB](https://www.steamgriddb.com/) for any custom steam shortcut. ## Very early alpha This tool is still in very early alpha, there are still lots of things to do. -Currently it will only work if you have steam installed at the default location, and there are no options for configuration, or for scheduling recuring synchronizations. -Also only Epic Games and Legendary are supported at the moment. +Currently it is only a cli and there are no recuring synchronizations (you have to manully run it or schedule the run yourself). +Also only Epic Games and Legendary are supported at the moment, but many more are planned. It is a Minimal Viable Product currently, I will update it with new features and bug fixes as I get time. @@ -26,7 +26,34 @@ Feel free to submit issues and pull requests * Download the latest release from the [releases page](https://github.com/PhilipK/steam_shortcuts_sync/releases). * Place it in a folder of your choice. -* Create a file called `auth_key.txt` in the same folder as the executable. -* Write your [SteamGridDB API key](https://www.steamgriddb.com/profile/preferences/api) in the `auth_key.txt` file. -* Run the executable! -* Restart Steam to see your new shortcuts. \ No newline at end of file +* Create a file called `config.toml` in the same folder as the executable. +* Write your [SteamGridDB API key](https://www.steamgriddb.com/profile/preferences/api) in the `config.toml` file (see the [config section](#configuration)). +* Run the executable. +* Restart Steam to see your new shortcuts. + +## Configuration +The tool reads its configuration from a `config.toml` file. +Here is a simple example of how to write the config file: +```toml +[steamgrid_db] +auth_key="your steamgrid db auth key" +``` + +And here is a full example of all configuration options: +```toml + +[epic_games] +enabled=true #On windows this is default true, on linux default false +location="C:\ProgramData\Epic\EpicGamesLauncher" #If this value is not defined, the tool will try to find it automatically (only windows). If it can't find it, it will fail and tell you. + +[legendary] +enabled=false #On windows this is default false, on linux default true +executable="legendary" #If this value is not defined, "legendary" will be used, it is assumed to be on the path. + +[steam] +location="C:\\Program Files (x86)\\Steam\\" #If this value is not defined, the tool will try to find it automatically. If it can't find it, it will fail and tell you. + +[steamgrid_db] +enabled = true #If false, the whole download of custom art will be skipped. +auth_key="" #This value is mandatory if you have steamgrid_db enabled. +``` \ No newline at end of file diff --git a/src/defaultconfig.toml b/src/defaultconfig.toml index e5e532c..6d6d461 100644 --- a/src/defaultconfig.toml +++ b/src/defaultconfig.toml @@ -1,5 +1,9 @@ debug= false +[epic_games] + +[legendary] + [steam] [steamgrid_db] diff --git a/src/settings.rs b/src/settings.rs index fccc01d..bce7d03 100644 --- a/src/settings.rs +++ b/src/settings.rs @@ -47,9 +47,9 @@ impl Settings { // This file shouldn't be checked in to git s.merge(File::with_name("local.toml").required(false))?; - // Add in settings from the environment (with a prefix of STEAM_SYNC) - // Eg.. `STEAM_SYNC_DEBUG=1 ./target/app` would set the `debug` key - s.merge(Environment::with_prefix("steam_sync"))?; + // Add in settings from the environment (with a prefix of STEAMSYNC) + // Eg.. `STEAMSYNC_DEBUG=1 ./target/app` would set the `debug` key + s.merge(Environment::with_prefix("steamsync").separator("-"))?; s.try_into() }