slackbuilds/xap/nextcloud-client/SlackBuild

56 lines
1.1 KiB
Text
Raw Normal View History

#!/bin/sh
2014-03-16 07:20:55 +01:00
# variables
CWD=$(pwd)
PRGNAM=$(basename $CWD)
2018-06-28 16:00:05 +02:00
ARCH="AppImage"
2014-03-16 07:20:55 +01:00
BUILD=1
TAG=cyco
TMP=/tmp/$TAG
PKG=$TMP/pkg-$PRGNAM
OUTPUT=/tmp
PREFIX=/usr
# nettoyage préalable
rm -fr $PKG $TMP/$PRGNAM
2018-06-28 16:00:05 +02:00
mkdir -p $PKG/opt/$PRGNAM
2014-03-16 07:20:55 +01:00
# mise en place
2018-06-28 16:00:05 +02:00
cd $PKG/opt/$PRGNAM
2014-03-16 07:20:55 +01:00
2018-06-28 16:00:05 +02:00
wget -c https://download.nextcloud.com/desktop/daily/Linux/latest.AppImage -O ${PRGNAM}.AppImage
chmod +x ${PRGNAM}.AppImage
VERSION=$( ./${PRGNAM}.AppImage --help | grep version | sed 's/Nextcloud version //' | sed 's/ (build /_/' | tr -d \))
2014-03-16 07:20:55 +01:00
2018-06-28 16:00:05 +02:00
mkdir -p $PKG$PREFIX/bin/
( cd $PKG$PREFIX/bin/
# ln -s ../../opt/$PRGNAM/${PRGNAM}.AppImage $PRGNAM
ln -s ../../opt/$PRGNAM/${PRGNAM}.AppImage nextcloud
)
2014-03-16 07:20:55 +01:00
# 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
2014-03-16 07:20:55 +01:00
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM:
$PRGNAM: https://github.com/nextcloud/client_theming
2014-03-16 07:20:55 +01:00
$PRGNAM:
EOF
# empaquetage
makepkg -l y -c n $OUTPUT/$PRGNAM-$(echo $VERSION | sed 's/-//g')-$ARCH-$BUILD$TAG.txz