appdwarf/apps/mkwine

16 lines
512 B
Plaintext
Raw Normal View History

#!/bin/sh
APP=${0#./mk}
DIR=/tmp/appdwarf/$APP
mkdir -p "$DIR"
VER=Kron4ek/Wine-Builds
[ "$1" = "proton" ] && VER=GloriousEggroll/proton-ge-custom && shift
LINK=$(curl -L api.github.com/repos/$VER/releases | jq .[0].assets[1] | grep -om1 g.\*tar..z)
curl -L "$LINK" | bsdtar xf - -C"$DIR"
mv "$DIR"/wine*/* "$DIR"/GE-Proton*/files/* "$DIR"
t=winetricks; wget -O"$DIR"/bin/$t github.com/$t/$t/raw/master/src/$t
chmod +x "$DIR"/bin/$t
appdwarf -b "$DIR"/AppRun
appdwarf "$DIR" "$@"
mv "$DIR".sh wine
rm -rf "$DIR"