+squirrelmail-cn (2:1.4.9a-5) stable; urgency=low
+
+ * Tranzicijski paket za buduci prelazak na Debian Lenny.
+ * Ovisnosti o drugim paketima, debian/control datoteka:
+ + ovisnost o squirrelmail (>= 2:1.4.9a-3),
+ + ovisnost o debconf (>= 1.4.72),
+ + ovisnost o apache-common paketu je uklonjena; apache-common
+ paket vise nije dostupan u Debian Lenny,
+ + uklonjena preporuka za uw-imap-ssl-cn paket.
+ * Novi dio paketa: debian/config, debian/templates,
+ debian/postrm, squirrelmail-cn.css.
+ * U slucaju da se postavke za $default_left_size i $theme_css
+ unutar /etc/squirrelmail/config.php razlikuju od preporucenih,
+ korisniku je ponudjen izbor da aktivira preporucene postavke
+ (kroz debian/config).
+ * Izmjene unutar debian/postinst datoteke:
+ + funkcija listconffiles() umjesto skripte listconffiles iz
+ apache-common paketa,
+ + podesavanje sirine lijevog okvira unutar Squirrelmail web
+ sucelja na '220', ovisno o korisnikovom odgovoru,
+ + podesavanje CSS datoteke za Squirrelmail web sucelje na
+ 'squirrelmail-cn.css', ovisno o korisnikovom odgovoru.
+
+ -- Dragan Dosen <ddosen@ffzg.hr> Wed, 17 Dec 2008 15:46:35 +0100
+
squirrelmail-cn (2:1.4.9a-4) stable; urgency=low
* Izmjene unutar debian/preinst datoteke: brisanje divertova
--- /dev/null
+#!/bin/sh
+
+set -e
+
+# Load debconf
+. /usr/share/debconf/confmodule
+
+if [ "$1" != reconfigure ]; then
+ for item in leftwidth themecss; do
+ db_fget squirrelmail-cn/${item} seen
+ if [ "$RET" = "true" ]; then
+ exit 0
+ fi
+ done
+fi
+
+SMDIR="/etc/squirrelmail"
+SMCONF="$SMDIR/config.php"
+change_default=1
+
+
+# Check $default_left_size in SM's config.php
+#
+if [ -f "$SMCONF" ]; then
+ if egrep -q "^[[:space:]]*\\\$default_left_size[[:space:]]*=[[:space:]]*'220'" "$SMCONF"; then
+ change_default=0
+ fi
+fi
+if [ $change_default -eq 1 ]; then
+
+ # Ask user for changing $default_left_size to '220'.
+ db_input critical squirrelmail-cn/leftwidth || true
+ db_go || true
+else
+ db_set squirrelmail-cn/leftwidth false || true
+ db_fset squirrelmail-cn/leftwidth seen true
+ change_default=1
+fi
+
+# Check $theme_css in SM's config.php
+#
+if [ -f "$SMCONF" ]; then
+ if egrep -q "^[[:space:]]*\\\$theme_css[[:space:]]*=[[:space:]]*SM_PATH[[:space:]]*\.
+[[:space:]]*'themes\/css\/squirrelmail-cn\.css'" "$SMCONF"; then
+ change_default=0
+ fi
+fi
+if [ $change_default -eq 1 ]; then
+
+ # Ask user for changing $theme_css to 'squirrelmail-cn.css'.
+ db_input critical squirrelmail-cn/themecss || true
+ db_go || true
+else
+ db_set squirrelmail-cn/themecss false || true
+ db_fset squirrelmail-cn/themecss seen true
+fi
+
+exit 0
Package: squirrelmail-cn
Architecture: all
Pre-Depends: apache2-cn (>= 2.2), php5-cn | php4-cn
-Depends: squirrelmail (>= 2:1.4.4-11), squirrelmail-locales (>= 1.4.9-20070106-1), apache-common (>= 1.3.34-4.1), carnet-tools-cn (>= 2.0), hostname, locales
-Recommends: dovecot-cn | uw-imap-ssl-cn | imap-server
+Depends: squirrelmail (>= 2:1.4.9a-3), squirrelmail-locales (>= 1.4.9-20070106-1), debconf (>= 1.4.72), carnet-tools-cn (>= 2.0), hostname, locales
+Recommends: dovecot-cn | imap-server
Description: Webmail for nuts
SquirrelMail is a standards-based webmail package written in PHP. It
includes built-in pure PHP support for the IMAP and SMTP protocols, and
[ "$DEBIAN_SCRIPT_DEBUG" ] && set -x
+# Source debconf library.
+. /usr/share/debconf/confmodule
+
case "$1" in
configure)
# continue below
fi
}
+# listconffiles ()
+#
+# Recursively walks /etc/apache2/apache2.conf for Include directives.
+# Returns all configfiles so defined.
+#
+function listconffiles () {
+
+ local i incs
+
+ incs=`awk 'tolower($1) == "include" { sub("/$","/*",$2); print $2; }' $1`
+ if [ -n "$incs" ]; then
+ for i in $incs; do
+ if [ -e "$i" ]; then echo "$i"; listconffiles "$i"; fi
+ done
+ fi
+}
+
reload=""
DATE=`date +%Y-%m-%d.%H:%M:%S`
# (directory /etc/apache2/conf.d/), but only if we are not present in
# Apache2 configuration at all.
#
-# We're using listconffiles from apache-common Debian package. Yes,
-# it works with Apache2 configurations too.
+# We're not using listconffiles from apache-common Debian package.
+# apache-common is no longer available in Debian Lenny. We're using
+# listconffiles() function instead.
#
-apache2listconf=`/usr/share/apache/listconffiles -V $hconf | tr '\a' ' ' | grep "$CONF"` || true
+apache2listconf=`listconffiles "$hconf" | grep "$CONF"` || true
apache2squirrel=`ls -l /etc/apache2/conf.d/ | grep "$CONF"` || true
if [ -z "$apache2listconf" -a -z "$apache2squirrel" ]; then
/^[ ]*\\\$data_dir[ ]*=/s/\.\.\/data\//\/var\/lib\/squirrelmail\/data\//;
"
-# Check for our uw-imap package; if it is installed, assume it's used.
+# Left frame size to 220px.
+# $default_left_size = '220';
+#
+db_get squirrelmail-cn/leftwidth || true
+if [ "$RET" = "true" ]; then
+ seddef="$seddef/^[ ]*\\\$default_left_size[ ]*=/s/'[0-9]*'/'220'/;
+ "
+fi
+
+# Change CSS file for Squirrelmail.
+# $theme_css = SM_PATH . 'themes/css/squirrelmail-cn.css';
#
-if dpkg -l uw-imap-ssl-cn 2>/dev/null | grep -q '^ii'; then
- seddef="$seddef/^[ ]*\\\$imap_server_type[ ]*=/ {s/cyrus/uw/;s/other/uw/;}
+db_get squirrelmail-cn/themecss || true
+if [ "$RET" = "true" ]; then
+ seddef="$seddef/^[ ]*\\\$theme_css[ ]*=/s/=.*/= SM_PATH . 'themes\/css\/squirrelmail-cn.css';/;
"
fi
+db_stop || true
+
# Check for our dovecot package; if it is installed, assume it's used.
#
if dpkg -l dovecot-cn 2>/dev/null | grep -q '^ii'; then
--- /dev/null
+#!/bin/sh
+
+set -e
+
+if [ "$1" = purge -a -e /usr/share/debconf/confmodule ]; then
+ . /usr/share/debconf/confmodule
+ db_purge
+fi
+
+exit 0
--- /dev/null
+Template: squirrelmail-cn/leftwidth
+Type: boolean
+Description: Zelite li aktivirati preporucenu postavku za Squirrelmail?
+ Provjerom trenutne Squirrelmail konfiguracije (konfiguracijska datoteka
+ /etc/squirrelmail/config.php), ustanovljeno je da sirina lijevog okvira
+ unutar Squirrelmail web sucelja nije 220 piksela.
+ .
+ Kako bi Squirrelmail web sucelje korisnicima bilo preglednije,
+ preporucamo da postavite sirinu lijevog okvira na 220 piksela.
+
+Template: squirrelmail-cn/themecss
+Type: boolean
+Description: Zelite li aktivirati preporucenu postavku za Squirrelmail?
+ Provjerom trenutne Squirrelmail konfiguracije (konfiguracijska datoteka
+ /etc/squirrelmail/config.php), ustanovljeno je da trenutno ne koristite
+ preporucenu CSS datoteku (squirrelmail-cn.css).
+ .
+ Unutar CSS datoteke (squirrelmail-cn.css) dodatno su podeseni fontovi i
+ njihova velicina kako bi Squirrelmail web sucelje korisnicima bilo
+ preglednije.
--- /dev/null
+body, td, th, dd, dt, h1, h2, h3, h4, h5, h6, p, ol, ul, li, input, select {
+ font-family: Verdana, Arial, Helvetica, sans-serif;
+}
+
+body, small {
+ font-size: 8pt;
+}
+
+p {
+ font-size: 9pt;
+ color: #707070;
+}
+
+a:hover {
+ text-decoration: none;
+}
+
+a:active {
+ text-decoration: underline;
+}
+
+ol, ul, li {
+ font-size: 10pt;
+}
+
+td, th {
+ font-size: 10pt;
+}
+
+tr {
+ font-size: 10pt;
+}
+
+dd, dt {
+ font-size: 10pt;
+}
+
+textarea, pre, nobr {
+ font-family: monospace;
+ font-size: 9pt;
+}
+
+input, select {
+ font-size: 10pt;
+}