Progress on the create-install main function logic:

This commit is contained in:
wasabi
2025-05-29 19:14:30 -05:00
parent ad79e5cd98
commit 19b009f8ad
4 changed files with 154 additions and 102 deletions

View File

@@ -1,15 +1,20 @@
#!/usr/bin/env bash
install_steamtricks () {
curl | tar -xvC ~/.steamtricks/
export DOWNLOADURL=""
install_steamtricks () {
export SHELLNAME="$1"
export SHELLPROFILE="$HOME/.${SHELLNAME}rc"
mkdir -p ~/.steamtricks && curl "$DOWNLOADURL" | tar -xvC ~/.steamtricks/ || echo "Could not install steamtricks"
echo "export STEAMTRICKS_PREFIX=\"$HOME/.steamtricks\"">>$SHELLPROFILE
echo 'export PATH="$PATH:$HOME/.winetricks/bin"'>>$SHELLPROFILE
}
SHELLNAME=$(echo $SHELL | awk -F '/' '{print $NF}')
case "$SHELLNAME" in
sh) echo "Shell not supported"; exit 1
;;
bash | zsh | yash) install_steamtricks
bash | zsh | yash) install_steamtricks "$SHELLNAME"
;;
*) echo "You will need to install this by manually adding it to either your /etc/profile for system-wide installation or to your shell's profile"
;;