wok-current view autoblog/receipt @ rev 15685
linux-lxc: add post_install() for update menu.lst
author | Stanislas Leduc <shann@slitaz.org> |
---|---|
date | Sat Dec 21 07:21:07 2013 +0100 (2013-12-21) |
parents | b2a632fc9587 |
children | 372da2303ff1 |
line source
1 # SliTaz package receipt.
3 PACKAGE="autoblog"
4 VERSIONV1="0.1.31"
5 VERSIONV2="2.5.22" # need php 5.3
6 VERSION="$VERSIONV1"
7 CATEGORY="network"
8 SHORT_DESC="replicates articles from another blog."
9 MAINTAINER="pascal.bellard@slitaz.org"
10 LICENSE="PublicDomain"
11 TARBALL="$PACKAGE-$VERSION.php"
12 EXTRA_SOURCE_FILES="vvb.ini"
13 URLV1="http://sebsauvage.net/streisand.me/download.php"
14 URLV2="http://autoblog.kd2.org/source.txt"
15 URL="$URLV1"
16 WEB_SITE="http://sebsauvage.net/streisand.me/"
18 DEPENDS="php"
20 # Rules to configure and make the package.
21 compile_rules()
22 {
23 [ -s "$SOURCES_REPOSITORY/$TARBALL" ] ||
24 wget -O "$SOURCES_REPOSITORY/$TARBALL" $URL
25 [ -s "$SOURCES_REPOSITORY/vvb.ini" ] ||
26 wget -O "$SOURCES_REPOSITORY/vvb.ini" \
27 http://sebsauvage.net/streisand.me/sebsauvage/vvb.ini
28 mkdir -p $src 2> /dev/null
29 }
31 # Rules to gen a SliTaz package suitable for Tazpkg.
32 genpkg_rules()
33 {
34 mkdir -p $fs/var/www/$PACKAGE
35 cp $SOURCES_REPOSITORY/$_TARBALL $fs/var/www/$PACKAGE/index.php
36 cp $SOURCES_REPOSITORY/vvb.ini $fs/var/www/$PACKAGE/
37 dos2unix $fs/var/www/$PACKAGE/*
38 }
40 post_install()
41 {
42 mytz="$(cat $1/etc/TZ)"
43 [ -n "$mytz" ] && sed -i "s|Europe/Paris|$mytz|" $1/var/www/$PACKAGE/index.php
44 chown -R www $1/var/www/$PACKAGE
45 echo "You should update /var/www/$PACKAGE/vvb.ini now ..."
46 }