#!/bin/sh PRGNAM=emacswiki VERSION=$(date +"%Y.%m.%d_%H.%M") BUILD=${BUILD:-1} ARCH=emacs CWD=$(pwd) TAG=cyco OUTPUT=/tmp TMP=${TMP:-/tmp/$TAG} PKG=$TMP/pkg-$PRGNAM REPOSITORIES=/home/installs/SlackBuilds/repositories PREFIX=/usr rm -rf $PKG if [ ! -e $REPOSITORIES/$PRGNAM ] ; then svn checkout "http://svn.sv.gnu.org/svn/emacswiki/emacswikipages" $REPOSITORIES/$PRGNAM else ( cd $REPOSITORIES/$PRGNAM svn update ) fi mkdir -p $PKG/$PREFIX/doc/ ( cd $PKG/$PREFIX/doc/ cp -R $REPOSITORIES/$PRGNAM $PRGNAM rm -fr $PRGNAM/.svn ) mkdir -p $PKG$PREFIX/share/emacs/site-lisp/$PRGNAM/ ( cd $PKG$PREFIX/share/emacs/site-lisp/$PRGNAM/ for el in \ "no-word.el" \ "xml-rpc.el" \ "buffer-move.el" \ "goto-last-change.el" \ "fill-column-indicator.el" \ "php-mode-improved.el" \ "quick-jump.el" \ "alarm.el" \ "multi-term.el" \ "lusty-explorer.el" \ "sml-modeline.el" \ "apache-mode.el" \ "hexrgb.el" \ "palette.el" \ "pastebin.el" \ "openpaste.el" \ "snipplr.el" \ "legalese.el" \ "workspaces.el" \ "auto-complete.el" \ "gnugo.el" \ "http-post-simple.el" \ "facebook.el" \ "tumbl.el" \ "dom.el" \ "babel.el" \ "cheezburger.el" \ "jira.el" \ "folding.el" \ "sunrise-commander.el" \ "sunrise-x-buttons.el" \ "sunrise-x-checkpoints.el" \ "sunrise-x-loop.el" \ "sunrise-x-mirror.el" \ "sunrise-x-modeline.el" \ "sunrise-x-old-checkpoints.el" \ "sunrise-x-popviewer.el" \ "sunrise-x-tabs.el" \ "sunrise-x-tree.el" \ "typing.el" \ "wiki.el" \ "tidy.el" \ "fixme-mode.el" \ "work-timer.el" \ "showtip.el" \ "sdcv.el" \ "etxt.el" \ "htmlr.el" \ "cus-edit+.el" \ "xml-rpc.el" \ "weblogger.el" \ "newsticker-notify.el" ; do [ -e "$PKG$PREFIX/doc/$PRGNAM/$el" ] && ln -s "$PREFIX/doc/$PRGNAM/$el" "$el" ; done ) ( cd $PKG chown -R root:root . find . \ \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \ -exec chmod 755 {} \; -o \ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \ -exec chmod 644 {} \; mkdir -p $PKG/install cat < $PKG/install/slack-desc $PRGNAM: $PRGNAM (a local mirror of EmacsWiki) $PRGNAM: $PRGNAM: $PRGNAM: $PRGNAM: $PRGNAM: $PRGNAM: $PRGNAM: http://emacswiki.org/ $PRGNAM: $PRGNAM: $PRGNAM: EOF ) cd $PKG /sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.txz