slackbuilds/xap/nextcloud-desktop/SlackBuild.appImage

55 lines
1.1 KiB
Text
Raw Normal View History

#!/bin/bash -e
# variables
CWD=$(pwd)
VERSION=${VERSION:-$(curl -s https://api.github.com/repos/nextcloud/desktop/releases/latest | jq -r .tag_name)}
PRGNAM=$(basename $CWD)
ARCH="AppImage"
BUILD=1
2020-06-25 11:23:11 +02:00
TAG=gwh
TMP=/tmp/$TAG
PKG=$TMP/pkg-$PRGNAM
OUTPUT=/tmp
PREFIX=/usr
# nettoyage préalable
rm -fr $PKG
mkdir -p $PKG/opt/$PRGNAM
# mise en place
cd $PKG/opt/$PRGNAM
2024-10-21 21:30:29 +02:00
wget -c https://github.com/nextcloud-releases/desktop/releases/download/${VERSION}/Nextcloud-$(echo ${VERSION} | sed 's|^v||')-x86_64.AppImage -O ${PRGNAM}-${VERSION}.AppImage
chmod +x ${PRGNAM}-${VERSION}.AppImage
mkdir -p $PKG$PREFIX/bin/
cd $PKG$PREFIX/bin/
ln -s ../../opt/$PRGNAM/${PRGNAM}-${VERSION}.AppImage nextcloud
# correction
cd $PKG
chown -R root:root *
# embaumement
mkdir -p $PKG/install
cat <<EOF > $PKG/install/slack-desc
$PRGNAM: $PRGNAM (NextCloud Desktop Syncing Client)
$PRGNAM:
$PRGNAM: nextcloud themed desktop client
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM: https://github.com/nextcloud/client_theming
$PRGNAM:
EOF
# empaquetage
2023-08-16 12:23:26 +02:00
/sbin/makepkg --linkadd y --chown n --prepend $OUTPUT/$PRGNAM-$(echo $VERSION | sed 's/-//g')-$ARCH-$BUILD$TAG.txz