From 11dd8003a531327a3e1cb7b47f376d5e38547d09 Mon Sep 17 00:00:00 2001 From: dany Date: Wed, 5 Oct 2022 20:12:22 +0200 Subject: [PATCH] archive also release tar.gz along side with appImage --- mkimg.sh | 35 ++++++++++++++++++----------------- 1 file changed, 18 insertions(+), 17 deletions(-) diff --git a/mkimg.sh b/mkimg.sh index abaa3b9..f26d491 100755 --- a/mkimg.sh +++ b/mkimg.sh @@ -13,12 +13,15 @@ archname=x86_64 case $arch in amd64|x86_64) archname=x86_64 + suffix=x86_64 ;; aarch64|arm64) archname=aarch64 + suffix=aarch64 ;; armv7l|arm) archname=armhf + suffix=armv7l ;; *) echo "Unkown architecture" @@ -39,6 +42,20 @@ echo "Building app image for $arch" mkdir antos.AppDir +# copy all neccessary file +cp -rf $W/backend/build/$arch/* antos.AppDir/ + +cp -rf $W/frontend/$tag/build/* antos.AppDir/ + +cp antd-config.ini antos.AppDir/opt/www/ +cp runner.ini antos.AppDir/opt/www/ + +# create binary tar.gz +[ ! -d "build/$tag" ] && mkdir -p build/$tag +cd antos.AppDir +tar cvzf ../build/$tag/AntOS_$suffix.tar.gz + +cd ../ # AppRun cat << "EOF" >> antos.AppDir/AppRun #!/bin/sh @@ -70,24 +87,8 @@ Categories=Utility; Terminal=true EOF -# copy all neccessary file cp antos.png antos.AppDir -cp -rf $W/backend/build/$arch/* antos.AppDir/ - -cp -rf $W/frontend/$tag/build/* antos.AppDir/ - -cp antd-config.ini antos.AppDir/opt/www/ -cp runner.ini antos.AppDir/opt/www/ - tree antos.AppDir -./appimagetool.AppImage --runtime-file runtime-$archname antos.AppDir build/AntOS_$archname-$tag.AppImage -cd build -case $arch in - armv7l|arm) - mv AntOS_$archname-$tag.AppImage AntOS_armv7l-$tag.AppImage - ;; - *) - ;; -esac +./appimagetool.AppImage --runtime-file runtime-$archname antos.AppDir build/$tag/AntOS_$suffix.AppImage \ No newline at end of file