wok view hatenarunner/receipt @ rev 9689

startup-notification: clean up.
author Christopher Rogers <slaxemulator@gmail.com>
date Fri May 06 22:03:25 2011 +0000 (2011-05-06)
parents b50e6276ecc8
children bba1751b3cc0
line source
1 # SliTaz package receipt.
3 PACKAGE="hatenarunner"
4 VERSION="1.0"
5 CATEGORY="games"
6 SHORT_DESC="Loderunner game in javascript"
7 MAINTAINER="pascal.bellard@slitaz.org"
8 WEB_SITE="http://lodedome.no-ip.com/"
9 TARBALL="JavaScript_Hatena.Runner_Satoshi.Ueyama.zip"
10 #_WGET_URL="http://lodedome.no-ip.com/download.php?rfname=$TARBALL&request_id=Lode_5BBAB6F85D944A4A5CB7AC12B0BFD18D"
11 _WGET_URL="http://mirror.slitaz.org/sources/packages/${TARBALL:0:1}/$TARBALL"
13 # Rules to configure and make the package.
14 compile_rules()
15 {
16 mkdir $src
17 cd $src
18 if [ ! -s $SOURCES_REPOSITORY/$TARBALL ]; then
19 wget $_WGET_URL -O $TARBALL
20 mv $TARBALL $SOURCES_REPOSITORY
21 fi
22 unzip $SOURCES_REPOSITORY/$TARBALL
23 unzip HatenaRunner_MainGameScript.zip
24 rm -f HatenaRunner_MainGameScript.zip
25 dos2unix js/* *.htm *.css
26 # Add u, i, o, j, k, and l keys
27 sed -i -e 's/104:$/& case 73: case 105:/' \
28 -e 's/98:$/& case 75: case 107:/' \
29 -e 's/100:$/& case 74: case 106:/' \
30 -e 's/102:$/& case 76: case 108:/' \
31 -e 's/88:/& case 79: case 111:/' \
32 -e 's/90:/& case 85: case 117:/' \
33 js/key.js
34 sed -i -e 's/<title>.*</<title>Lode Runner</' \
35 -e 's/preStart()"/preStart(); javascript:init();"/' \
36 -e '/a href=/d' -e '/li>/d' -e '/ul>/d' -e '/Explorer/d' \
37 runner.htm
38 rm -rf images/start.png images/hrlogo.png ScreenS Docs Unknown \
39 users favicon.ico icon.png
40 mv runner.htm index.html
41 }
43 # Rules to gen a SliTaz package suitable for Tazpkg.
44 genpkg_rules()
45 {
46 mkdir -p $fs/var/www/lode $fs/usr/share/applications
47 cp -a $src/* $fs/var/www/lode
48 chown -R 80.80 $fs/var/www/lode
49 cat > $fs/usr/share/applications/lode.desktop <<EOT
50 [Desktop Entry]
51 Type=Application
52 Name=Lode runner
53 Exec=browser file:///var/www/lode/index.html
54 Icon=/var/www/lode/images/o0.gif
55 Terminal=false
56 Categories=Game;
57 Comment=Lode runner clone
58 EOT
59 }