2020-01-09 00:43:18 +01:00
|
|
|
#!/bin/bash
|
2020-01-12 20:28:57 +01:00
|
|
|
APP_NAME="bin/test_executable"
|
2020-01-09 00:43:18 +01:00
|
|
|
APP_ID=480
|
2020-01-12 20:28:57 +01:00
|
|
|
APP_PATH=$(dirname "$0")
|
|
|
|
CONFIG_PATH=$(dirname "$0")
|
2020-01-09 00:43:18 +01:00
|
|
|
|
2020-01-12 20:28:57 +01:00
|
|
|
CUR_DIR=$(pwd)
|
|
|
|
cd "$CONFIG_PATH"
|
2020-01-09 00:43:18 +01:00
|
|
|
mkdir -p ~/.steam/sdk64
|
|
|
|
mkdir -p ~/.steam/sdk32
|
2020-01-12 20:28:57 +01:00
|
|
|
rm -rf ~/.steam/sdk64/steam_settings
|
|
|
|
rm -rf ~/.steam/sdk32/steam_settings
|
2020-01-09 00:43:18 +01:00
|
|
|
#make a backup of original files
|
|
|
|
mv ~/.steam/steam.pid ~/.steam/steam.pid.orig || true
|
|
|
|
mv ~/.steam/sdk64/steamclient.so ~/.steam/sdk64/steamclient.so.orig || true
|
|
|
|
mv ~/.steam/sdk32/steamclient.so ~/.steam/sdk32/steamclient.so.orig || true
|
|
|
|
#copy our files
|
|
|
|
cp x86/steamclient.so ~/.steam/sdk32/steamclient.so
|
|
|
|
cp x86_64/steamclient.so ~/.steam/sdk64/steamclient.so
|
2020-01-12 20:28:57 +01:00
|
|
|
cp -r steam_settings ~/.steam/sdk32/
|
|
|
|
cp -r steam_settings ~/.steam/sdk64/
|
2020-01-09 00:43:18 +01:00
|
|
|
echo $BASHPID > ~/.steam/steam.pid
|
2020-01-12 20:28:57 +01:00
|
|
|
cd "$APP_PATH"
|
|
|
|
SteamAppId=$APP_ID SteamGameId=$APP_ID "$APP_NAME"
|
|
|
|
cd "$CUR_DIR"
|
2020-01-09 00:43:18 +01:00
|
|
|
#restore original
|
|
|
|
rm -f ~/.steam/steam.pid
|
|
|
|
rm -f ~/.steam/sdk64/steamclient.so
|
|
|
|
rm -f ~/.steam/sdk32/steamclient.so
|
2020-01-12 20:28:57 +01:00
|
|
|
rm -rf ~/.steam/sdk64/steam_settings
|
|
|
|
rm -rf ~/.steam/sdk32/steam_settings
|
2020-01-09 00:43:18 +01:00
|
|
|
mv ~/.steam/steam.pid.orig ~/.steam/steam.pid
|
|
|
|
mv ~/.steam/sdk64/steamclient.so.orig ~/.steam/sdk64/steamclient.so || true
|
|
|
|
mv ~/.steam/sdk32/steamclient.so.orig ~/.steam/sdk32/steamclient.so || true
|