mirror of
https://codeberg.org/gwh/slackbuilds.git
synced 2024-11-16 19:51:19 +01:00
56 lines
998 B
Bash
Executable file
56 lines
998 B
Bash
Executable file
#!/bin/sh
|
|
|
|
CWD=$(pwd)
|
|
|
|
PRGNAM=$(basename $CWD)
|
|
VERSION=$(date +"%Y.%m.%d_%H.%M")
|
|
BUILD=1
|
|
|
|
ARCH=noarch
|
|
|
|
REPOSITORIES=/home/installs/SlackBuilds/repositories
|
|
|
|
TAG=cyco
|
|
TMP=/tmp/$TAG
|
|
PKG=$TMP/pkg-$PRGNAM
|
|
OUTPUT=/tmp
|
|
|
|
PREFIX=/usr
|
|
|
|
# cleaning
|
|
rm -fr $PKG
|
|
|
|
# get sources
|
|
[ ! -e $REPOSITORIES ] && mkdir -p $REPOSITORIES
|
|
if [ -e $REPOSITORIES/$PRGNAM ] ; then
|
|
( cd $REPOSITORIES/$PRGNAM
|
|
git pull
|
|
)
|
|
else
|
|
git clone http://github.com/arcturo/library.git $REPOSITORIES/$PRGNAM
|
|
fi
|
|
|
|
mkdir -p $PKG$PREFIX/doc/
|
|
cp -R $REPOSITORIES/$PRGNAM $PKG$PREFIX/doc/$PRGNAM
|
|
find $PKG$PREFIX/doc/$PRGNAM -name \.git\* -exec rm -fr {} \;
|
|
|
|
( cd $PKG
|
|
mkdir -p install
|
|
cat <<EOF > install/slack-desc
|
|
$PRGNAM: $PRGNAM (Free eBooks)
|
|
$PRGNAM:
|
|
$PRGNAM: about Coffee-script and stuff
|
|
$PRGNAM:
|
|
$PRGNAM:
|
|
$PRGNAM:
|
|
$PRGNAM:
|
|
$PRGNAM:
|
|
$PRGNAM:
|
|
$PRGNAM: http://github.com/arcturo/library#readme
|
|
$PRGNAM:
|
|
EOF
|
|
|
|
chown -R root:root *
|
|
|
|
makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.txz
|
|
)
|