From 21cd5051195e6d72c45821e3e0691378a9ebf0b1 Mon Sep 17 00:00:00 2001 From: Philipp Date: Thu, 22 Jul 2021 00:10:38 +0200 Subject: [PATCH] Add help text to script. Signed-off-by: Philipp --- README.md | 4 ++-- default.nix | 7 ++++++- helpText.txt | 12 ++++++++++++ 3 files changed, 20 insertions(+), 3 deletions(-) create mode 100644 helpText.txt diff --git a/README.md b/README.md index d21c103..87cc3e0 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ changes. The volatile nature of the `WINEPREFIX` leads to challenges in regards to preservation of needed state, this is handled in the following ways: -* The Application in itself and the Launcher folder containing the +* The Application in itself and the launcher folder containing the session data are created in the users home directory and symlinked into each prefix. * Internal wine settings are handled as registry files and automatically @@ -57,7 +57,7 @@ into the `Program Files` folder of the prefixs. `starcitizen --wine winecfg` # Disclaimer -This repository does not host any copyrighted content. All contend is fetched +This repository does not host any copyrighted content. All content is fetched from official sources and is never redistributed by the author of this software. It does not help in any way to cheat or pirate the game. A normal account is still needed to install or play the game. diff --git a/default.nix b/default.nix index 77fce8d..4621b8b 100644 --- a/default.nix +++ b/default.nix @@ -41,6 +41,11 @@ let name = "captureMouse.reg"; text = ./captureMouse.reg; }; + helpText = pkgs.writeTextFile { + name = "scHelptext"; + text = ./helpText.txt; + }; + script = pkgs.writeShellScriptBin binName '' #sane bash set -eo pipefail @@ -119,7 +124,7 @@ let } function help () { - echo "Gid gud!" + cat ${helpText.text} } function wine () { diff --git a/helpText.txt b/helpText.txt new file mode 100644 index 0000000..0515ba6 --- /dev/null +++ b/helpText.txt @@ -0,0 +1,12 @@ +Usage: `starcitizen [parameters]` + +Parameters: +`--install-prefix`: Installs the prefix if needed. +`--install-launcher`: Installs the launcher. Can be used to reinstall. +`--clean`: Deletes all but the currently used prefixes of the game. +`--remove-prefix`: Deletes the currently used prefix. Use with care. +`--run-game`: Runs the game (after installing the prefix if needed). Default behaviour. +`--print-prefix`: Prints the current prefix path. +`--help`: Prints help text. +`--wine`: Runs a wine executable inside the context of the script. Example: + `starcitizen --wine winecfg`