wok-6.x view hatenarunner/receipt @ rev 14524

Up: transmission-web (2.52)
author Richard Dunbar <mojo@slitaz.org>
date Fri May 17 03:24:31 2013 +0000 (2013-05-17)
parents 84d10fcd74e8
children de49f29b101e
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 cd $src
17 unzip -o HatenaRunner_MainGameScript.zip
18 rm -f HatenaRunner_MainGameScript.zip
19 dos2unix js/* *.htm *.css
20 # Add u, i, o, j, k, and l keys
21 sed -i -e 's/104:$/& case 73: case 105:/' \
22 -e 's/98:$/& case 75: case 107:/' \
23 -e 's/100:$/& case 74: case 106:/' \
24 -e 's/102:$/& case 76: case 108:/' \
25 -e 's/88:/& case 79: case 111:/' \
26 -e 's/90:/& case 85: case 117:/' \
27 js/key.js
28 sed -i -e 's/<title>.*</<title>Lode Runner</' \
29 -e 's/preStart()"/preStart(); javascript:init();"/' \
30 -e '/a href=/d' -e '/li>/d' -e '/ul>/d' -e '/Explorer/d' \
31 runner.htm
32 rm -rf images/start.png images/hrlogo.png ScreenS Docs Unknown \
33 users favicon.ico icon.png
34 mv runner.htm index.html
35 }
37 # Rules to gen a SliTaz package suitable for Tazpkg.
38 genpkg_rules()
39 {
40 mkdir -p $fs/var/www/lode $fs/usr/share/applications
41 cp -a $src/* $fs/var/www/lode
42 chown -R 80.80 $fs/var/www/lode
43 cat > $fs/usr/share/applications/lode.desktop <<EOT
44 [Desktop Entry]
45 Type=Application
46 Name=Lode runner
47 Exec=browser file:///var/www/lode/index.html
48 Icon=/var/www/lode/images/o0.gif
49 Terminal=false
50 Categories=Game;
51 Comment=Lode runner clone
52 EOT
53 }