Skip to content

Commit

Permalink
New automatic installation
Browse files Browse the repository at this point in the history
  • Loading branch information
Vvorcun authored May 25, 2023
1 parent 410eed9 commit 396de88
Showing 1 changed file with 19 additions and 19 deletions.
38 changes: 19 additions & 19 deletions Virtual Succubus.app/Contents/MacOS/Virtual Succubus
Original file line number Diff line number Diff line change
@@ -1,30 +1,30 @@
#!/bin/sh

ARCHIVENAME=""

if [ ! -f "$(dirname "$0")/../Resources/prefix/drive_c/Program Files (x86)/Virtual Succubus/Virtual Succubus.exe" ]; then
cd "$(dirname "$0")/../../.."
while [ ! -f "$ARCHIVENAME" ]; do
ARCHIVENAME=$(osascript -e 'set ArchiveName to text returned of (display dialog "Enter the name of VS installation archive (example: VS_0.39R3 PCFULL.zip)" default answer "VS_0.39R3 PCFULL.zip" buttons{"Continue"})')
while [ ! -f "$ARCHIVEPATH" ]; do
ARCHIVEPATH=$(osascript -e 'set archivePath to POSIX path of (choose file with prompt "Please select VS installation archive:" of type {"zip"})')
if [ ! $ARCHIVEPATH ]; then
exit 0
fi
done
FOLDERNAME=$(echo $ARCHIVENAME | sed 's/....$//')
unzip "$ARCHIVENAME" -d "Virtual Succubus.app/Contents/Resources/prefix/drive_c/Program Files (x86)"
FOLDERNAME=$(basename "$ARCHIVEPATH" .zip)
unzip "$ARCHIVEPATH" -d "Virtual Succubus.app/Contents/Resources/prefix/drive_c/Program Files (x86)"
mv "Virtual Succubus.app/Contents/Resources/prefix/drive_c/Program Files (x86)/$FOLDERNAME" "Virtual Succubus.app/Contents/Resources/prefix/drive_c/Program Files (x86)/Virtual Succubus"
osascript -e 'display alert "Virtual Succubus is successfully installed!" message "Restart an application in order to run it."'
exit 0
fi

if [ ! -d "$HOME/Library/Application Support/SuccuDev/" ]; then
echo "wrapper: SuccuDev directory not present, creating one"
mkdir "$HOME/Library/Application Support/SuccuDev/"
else
echo "wrapper: SuccuDev directory is present, starting wrapper"
fi
if [ ! -d "$HOME/Library/Application Support/SuccuDev/" ]; then
echo "wrapper: SuccuDev directory not present, creating one"
mkdir "$HOME/Library/Application Support/SuccuDev/"
else
echo "wrapper: SuccuDev directory is present, starting wrapper"
fi

cd "$(dirname "$0")/../Resources/prefix/drive_c/"
cd "$(dirname "$0")/../Resources/prefix/drive_c/"

export WINEPREFIX="$(dirname "$0")/../Resources/prefix/"
export WINEARCH="win64"
export WINEDEBUG=""
export WINEPREFIX="$(dirname "$0")/../Resources/prefix/"
export WINEARCH="win64"
export WINEDEBUG=""

../../../MacOS/wine64 "C:/Program Files (x86)/Virtual Succubus/Virtual Succubus.exe" "-force-feature-level-10-1"
../../../MacOS/wine64 "C:/Program Files (x86)/Virtual Succubus/Virtual Succubus.exe" "-force-feature-level-10-1"
fi

0 comments on commit 396de88

Please sign in to comment.