wok-4.x rev 7049
Add hatenarunner
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Mon Nov 01 11:41:47 2010 +0100 (2010-11-01) |
parents | 7485f69c1c89 |
children | 501287b71268 |
files | hatenarunner/receipt |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/hatenarunner/receipt Mon Nov 01 11:41:47 2010 +0100 1.3 @@ -0,0 +1,59 @@ 1.4 +# SliTaz package receipt. 1.5 + 1.6 +PACKAGE="hatenarunner" 1.7 +VERSION="1.0" 1.8 +CATEGORY="games" 1.9 +SHORT_DESC="Loderunner game in javascript" 1.10 +MAINTAINER="pascal.bellard@slitaz.org" 1.11 +WEB_SITE="http://lodedome.no-ip.com/" 1.12 +TARBALL="JavaScript_Hatena.Runner_Satoshi.Ueyama.zip" 1.13 +_WGET_URL="http://lodedome.no-ip.com/download.php?rfname=$TARBALL&request_id=Lode_5BBAB6F85D944A4A5CB7AC12B0BFD18D" 1.14 + 1.15 +# Rules to configure and make the package. 1.16 +compile_rules() 1.17 +{ 1.18 + mkdir $src 1.19 + cd $src 1.20 + if [ ! -s $SOURCES_REPOSITORY/$TARBALL ]; then 1.21 + wget $_WGET_URL -O $TARBALL 1.22 + mv $TARBALL $SOURCES_REPOSITORY 1.23 + fi 1.24 + unzip $SOURCES_REPOSITORY/$TARBALL 1.25 + unzip HatenaRunner_MainGameScript.zip 1.26 + rm -f HatenaRunner_MainGameScript.zip 1.27 + dos2unix js/* *.htm *.css 1.28 + # Add u, i, o, j, k, and l keys 1.29 + sed -i -e 's/104:$/& case 73: case 105:/' \ 1.30 + -e 's/98:$/& case 75: case 107:/' \ 1.31 + -e 's/100:$/& case 74: case 106:/' \ 1.32 + -e 's/102:$/& case 76: case 108:/' \ 1.33 + -e 's/88:/& case 79: case 111:/' \ 1.34 + -e 's/90:/& case 85: case 117:/' \ 1.35 + js/key.js 1.36 + sed -i -e 's/<title>.*</<title>Lode Runner</' \ 1.37 + -e 's/preStart()"/preStart(); javascript:init();"/' \ 1.38 + -e '/a href=/d' -e '/li>/d' -e '/ul>/d' -e '/Explorer/d' \ 1.39 + runner.htm 1.40 + rm -rf images/start.png images/hrlogo.png ScreenS Docs Unknown \ 1.41 + users favicon.ico icon.png 1.42 + mv runner.htm index.html 1.43 +} 1.44 + 1.45 +# Rules to gen a SliTaz package suitable for Tazpkg. 1.46 +genpkg_rules() 1.47 +{ 1.48 + mkdir -p $fs/var/www/lode $fs/usr/share/applications 1.49 + cp -a $src/* $fs/var/www/lode 1.50 + chown -R 80.80 $fs/var/www/lode 1.51 + cat > $fs/usr/share/applications/lode.desktop <<EOT 1.52 +[Desktop Entry] 1.53 +Type=Application 1.54 +Name=Lode runner 1.55 +Exec=browser file:///var/www/lode/index.html 1.56 +Icon=/var/www/lode/images/o0.gif 1.57 +Terminal=false 1.58 +Categories=Game; 1.59 +Comment=Lode runner clone 1.60 +EOT 1.61 +} 1.62 +