From 265a7f60260d021eaa876037c0c8fd252cdc2510 Mon Sep 17 00:00:00 2001 From: Gwenhael Le Moine Date: Mon, 11 Apr 2011 09:00:30 +0700 Subject: [PATCH] Added, a php framework --- web/klein.php/klein.php.SlackBuild | 57 ++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100755 web/klein.php/klein.php.SlackBuild diff --git a/web/klein.php/klein.php.SlackBuild b/web/klein.php/klein.php.SlackBuild new file mode 100755 index 00000000..d8f88f62 --- /dev/null +++ b/web/klein.php/klein.php.SlackBuild @@ -0,0 +1,57 @@ +#!/bin/sh + +CWD=$(pwd) + +PRGNAM=$(basename $CWD) +VERSION=git$(date +%Y.%m.%d_%H.%M) +BUILD=1 + +ARCH=$(uname -m) + +REPOSITORIES=/home/cycojesus/projets/packages/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 +( cd $REPOSITORIES + if [ -e $REPOSITORIES/$PRGNAM ] ; then + ( cd $REPOSITORIES/$PRGNAM + git pull + ) + else + git clone "https://github.com/chriso/klein.php.git" $REPOSITORIES/$PRGNAM + fi +) + +mkdir -p $PKG/srv/www/htdocs +cp -R $REPOSITORIES/$PRGNAM $PKG/srv/www/htdocs/ +find $PKG/srv/www/htdocs -name \.git\* -exec rm -fr {} \; + +cd $PKG +mkdir -p install +cat < install/slack-desc +$PRGNAM: $PRGNAM (A lightning fast router for PHP5.3+) +$PRGNAM: +$PRGNAM: klein.php is a lightning fast router for PHP 5.3+. In < 600 lines you get +$PRGNAM: Sinatra-like routing +$PRGNAM: Almost no overhead = as much speed as you can possibly squeeze from PHP +$PRGNAM: (2200 requests/second+) +$PRGNAM: A set of boilerplate methods for rapidly building web apps +$PRGNAM: +$PRGNAM: +$PRGNAM: https://github.com/chriso/klein.php +$PRGNAM: +EOF + +chown -R root:root * + +makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.txz