From 0858bfbfe2bda11a40591f8520aaf207e93a2af0 Mon Sep 17 00:00:00 2001 From: Gwenhael Le Moine Date: Sun, 31 Oct 2010 22:48:03 +0700 Subject: [PATCH] =?UTF-8?q?Add=20e/egg,=20magit=20=C2=ABclone=C2=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- e/egg/egg.SlackBuild | 78 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 78 insertions(+) create mode 100755 e/egg/egg.SlackBuild diff --git a/e/egg/egg.SlackBuild b/e/egg/egg.SlackBuild new file mode 100755 index 00000000..029e2998 --- /dev/null +++ b/e/egg/egg.SlackBuild @@ -0,0 +1,78 @@ +#!/bin/sh -x + +# variables +BRANCH=master +VERSION=${VERSION:-${BRANCH}_$(date +"%Y.%m.%d_%H.%M")} +ARCH=${ARCH:-$(uname -m)} +BUILD=${BUILD:-1} +PACKAGER=cyco + +TMP=/tmp/$PACKAGER +OUTPUT=/tmp +CWD=$(pwd) + +PRGNAM=$(basename $CWD) +PKG=$TMP/$PACKAGER/pkg-$PRGNAM + +REPOSITORY=/home/cycojesus/projets/packages/repositories/$PRGNAM +PREFIX=/usr + +EMACS=$(basename $(ls /usr/bin/emacs-2*)) +EMACS_VERSION=$(echo "$EMACS" | grep -o "[0-9\.]*") + +# nettoyage préalable +rm -fr $PKG $TMP/$PRGNAM-$VERSION + +mkdir -p $PKG$PREFIX/share/emacs/site-lisp + +# mise en place +cd $TMP +if [ ! -e $REPOSITORY ] ; then + mkdir -p $(dirname $REPOSITORY) + cd $(dirname $REPOSITORY) + git clone http://github.com/byplayer/egg.git $PRGNAM +fi + +( cd $REPOSITORY + git pull +) + +cp -R $REPOSITORY $PKG$PREFIX/share/emacs/site-lisp/$PRGNAM +# correction +( cd $PKG$PREFIX/share/emacs/site-lisp/$PRGNAM + find . -name .git\* -exec rm -fr {} \; + chown -R root:root * + + $EMACS -batch -f batch-byte-compile *.el + + mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION/ + mv doc/ CHANGELOG.markdown README.markdown $PKG/usr/doc/$PRGNAM-$VERSION/ +) + +# embaumement +mkdir -p $PKG/install +cat < $PKG/install/slack-desc +# HOW TO EDIT THIS FILE: +# The "handy ruler" below makes it easier to edit a package description. Line +# up the first '|' above the ':' following the base package name, and the '|' +# on the right side marks the last column you can put a character in. You must +# make exactly 11 lines for the formatting to be correct. It's also +# customary to leave one space after the ':'. + + |-----handy-ruler------------------------------------------------------| +$PRGNAM: $PRGNAM (Emacs Got Git) +$PRGNAM: +$PRGNAM: Egg is an Emacs interface to git. It's a suite composed of a +$PRGNAM: minor-mode and various special-buffers presenting different UIs to help +$PRGNAM: the user performing many git operations. +$PRGNAM: +$PRGNAM: +$PRGNAM: +$PRGNAM: +$PRGNAM: http://github.com/byplayer/egg +$PRGNAM: +EOF + +# empaquetage +cd $PKG +makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$PACKAGER.txz