wok annotate grooms/receipt @ rev 25466

Update some web_site
author Pascal Bellard <pascal.bellard@slitaz.org>
date Sat Oct 01 09:32:27 2022 +0000 (19 months ago)
parents aaae1f868d34
children
rev   line source
pascal@13478 1 # SliTaz package receipt.
pascal@13478 2
pascal@13478 3 PACKAGE="grooms"
Hans-G?nter@21003 4 VERSION="1.0.9"
pascal@13478 5 CATEGORY="games"
samuel_trassare@13680 6 SHORT_DESC="Play the board game, Go, over the Internet."
pascal@13478 7 MAINTAINER="pascal.bellard@slitaz.org"
pascal@15215 8 LICENSE="GPL2"
samuel_trassare@13680 9 WEB_SITE="http://$PACKAGE.tuxfamily.org"
Hans-G?nter@21003 10
pascal@13478 11 TARBALL="$PACKAGE-$VERSION.zip"
samuel_trassare@13680 12 WGET_URL="${WEB_SITE}/$TARBALL"
pascal@13478 13
pascal@13478 14 DEPENDS="php"
pascal@13478 15
pascal@24445 16 # What is the latest version available today?
pascal@24445 17 current_version()
pascal@24445 18 {
pascal@24445 19 wget -O - $WEB_SITE 2>/dev/null | \
pascal@24445 20 sed "/latest/d;/$PACKAGE-[0-9]/!d;/zip/!d;s|.*$PACKAGE-\\(.*\\).zip.*|\\1|" | sort -Vr | sed q
pascal@24445 21 }
pascal@24445 22
pascal@13478 23 # Rules to configure and make the package.
pascal@13478 24 compile_rules()
pascal@13478 25 {
Hans-G?nter@21003 26 :
pascal@13478 27 }
pascal@13478 28
pascal@13478 29 # Rules to gen a SliTaz package suitable for Tazpkg.
pascal@13478 30 genpkg_rules()
pascal@13478 31 {
pascal@13478 32 mkdir -p $fs/var/lib
pascal@13478 33 cp -a $src $fs/var/lib/grooms
pascal@13479 34 chown 80.80 $fs/var/lib/grooms
pascal@13478 35 }
pascal@13478 36
pascal@13478 37 post_install()
pascal@13478 38 {
pascal@13478 39 # Configure lighttpd server
pascal@18730 40 if [ -f "$1/etc/lighttpd/lighttpd.conf" ]; then
pascal@18730 41 if ! grep -q /var/lib/grooms "$1/etc/lighttpd/lighttpd.conf"; then
pascal@18730 42 sed -e 's|.*"/examples/" => "/usr/share/examples/",| "/examples/" => "/usr/share/examples/",\n "/grooms/" => "/var/lib/grooms/",|g' -i "$1/etc/lighttpd/lighttpd.conf"
pascal@13478 43 if [ -z "$1" ]; then
pascal@13478 44 # Start Web server.
pascal@13478 45 /etc/init.d/lighttpd stop
pascal@13478 46 /etc/init.d/lighttpd start
pascal@13478 47 fi
pascal@13478 48 fi
pascal@13478 49 fi
pascal@13478 50 # Configure apache server
pascal@18730 51 if [ -f "$1/etc/apache/httpd.conf" ]; then
pascal@18730 52 if [ ! -f "$1/etc/apache/conf.d/grooms" ]; then
pascal@18730 53 cat > "$1/etc/apache/conf.d/grooms" <<EOT
pascal@13478 54 <IfModule mod_alias.c>
pascal@13478 55 Alias /grooms /var/lib/grooms
pascal@13478 56 </IfModule>
pascal@13478 57 <Directory /var/lib/grooms/>
pascal@13478 58 DirectoryIndex index.php
pascal@13478 59 Options +FollowSymLinks
pascal@13478 60 AllowOverride None
pascal@13478 61 Order allow,deny
pascal@13478 62 Allow from all
pascal@13478 63 </Directory>
pascal@13478 64 EOT
pascal@13478 65 if [ -z "$1" ]; then
pascal@13478 66 # Start Web server.
pascal@13478 67 /etc/init.d/apache stop
pascal@13478 68 /etc/init.d/apache start
pascal@13478 69 fi
pascal@13478 70 fi
pascal@13478 71 fi
pascal@13478 72 }