wok-current view nanochess/receipt @ rev 7045
Add nanochess & p4wn
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Mon Nov 01 10:52:35 2010 +0100 (2010-11-01) |
parents | |
children | 7485f69c1c89 |
line source
1 # SliTaz package receipt.
3 PACKAGE="nanochess"
4 VERSION="1.0"
5 CATEGORY="games"
6 SHORT_DESC="Chess game in javascript (need an unicode aware browser)"
7 MAINTAINER="pascal.bellard@slitaz.org"
8 WEB_SITE="http://nanochess.110mb.com/chess4.html"
10 # Rules to configure and make the package.
11 compile_rules()
12 {
13 mkdir $src
14 cd $src
15 wget -O index.html \
16 $(dirname $WEB_SITE)/archive/toledo_javascript_chess_3.html
17 sed -i -e 's/<select/\♟ \→ &/' \
18 -e 's/f0f":"c0c")+"0f0/f0f":"606")+"0c0/' -e 's/e0e0f0/b0b080/' \
19 -e 's/><option.*$/>";/' -e 's|^doc.*|for(p=18;++p<23;)a+="<option>\b"+p+";</option>";document.write(a);|' \
20 index.html
21 }
23 # Rules to gen a SliTaz package suitable for Tazpkg.
24 genpkg_rules()
25 {
26 mkdir -p $fs/var/www/chess $fs/usr/share/applications
27 cp $src/* $fs/var/www/chess
28 chown -R 80.80 $fs/var/www/chess
29 cat > $fs/usr/share/applications/chess.desktop <<EOT
30 [Desktop Entry]
31 Type=Application
32 Name=Chess
33 Exec=browser file:///var/www/chess/index.html
34 Icon=other.png
35 Terminal=false
36 Categories=Game;
37 Comment=Chess game
38 EOT
39 }