-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathbuild.sh
26 lines (22 loc) · 967 Bytes
/
build.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#!/bin/sh
chmod +x AppDir/AppRun
echo "Download wine..."
LATEST_WINE=$(curl -L "https://api.github.com/repos/mmtrt/WINE_AppImage/releases/latest" | jq -r .assets[0].browser_download_url)
curl -L $LATEST_WINE -o AppDir/wine.AppImage
chmod +x AppDir/wine.AppImage
if ! command -v appimagetool.AppImage >/dev/null 2>&1
then
echo "Download AppImage tool..."
LATEST_TOOL=$(curl -L "https://api.github.com/repos/AppImage/AppImageKit/releases/latest" | jq -r '.assets[] | select(.name | test("appimagetool-x86_64.AppImage$")) | .browser_download_url')
curl -L $LATEST_TOOL -o appimagetool.AppImage
chmod +x appimagetool.AppImage
fi
echo "Download winbox..."
curl -L https://mt.lv/winbox64 -o AppDir/winbox64.exe
echo "Build AppImage..."
if command -v appimagetool.AppImage >/dev/null 2>&1
then ARCH=x86_64 appimagetool.AppImage -v AppDir
else
ARCH=x86_64 ./appimagetool.AppImage --appimage-extract-and-run -v AppDir
rm ./appimagetool.AppImage
fi