[Pkg-voip-commits] r3729 - in destar/trunk/debian: . po
santiago at alioth.debian.org
santiago at alioth.debian.org
Mon Jul 9 05:54:27 UTC 2007
Author: santiago
Date: 2007-07-09 05:54:26 +0000 (Mon, 09 Jul 2007)
New Revision: 3729
Added:
destar/trunk/debian/config
destar/trunk/debian/po/
destar/trunk/debian/po/POTFILES.in
destar/trunk/debian/po/templates.pot
destar/trunk/debian/templates
Modified:
destar/trunk/debian/control
destar/trunk/debian/postinst
destar/trunk/debian/rules
Log:
Trying debconf
Added: destar/trunk/debian/config
===================================================================
--- destar/trunk/debian/config (rev 0)
+++ destar/trunk/debian/config 2007-07-09 05:54:26 UTC (rev 3729)
@@ -0,0 +1,21 @@
+#!/bin/sh -e
+
+. /usr/share/debconf/confmodule
+
+if [ -f /etc/default/destar ]
+then
+ for v in `grep -E "^(PORT)=" /etc/ssmtp/ssmtp.conf`
+ do
+ export $v
+ done
+
+ if [ -n "$PORT" ]
+ then
+ db_set destar/port "$PORT"
+ fi
+fi
+
+db_input medium destar/port || true
+db_go
+
+exit 0
Modified: destar/trunk/debian/control
===================================================================
--- destar/trunk/debian/control 2007-07-08 17:36:49 UTC (rev 3728)
+++ destar/trunk/debian/control 2007-07-09 05:54:26 UTC (rev 3729)
@@ -3,7 +3,7 @@
Priority: optional
Maintainer: Debian VoIP Team <pkg-voip-maintainers at lists.alioth.debian.org>
Uploaders: Santiago Ruano Rincón <santiago at debian.org>, Alejandro Rios P. <alejandro.rios at avatar.com.co>, Mark Purcell <msp at debian.org>
-Build-Depends: debhelper (>= 5.0.37.2), dpatch
+Build-Depends: debhelper (>= 5.0.37.2), dpatch, po-debconf
Build-Depends-Indep: python
Standards-Version: 3.7.2
XS-Vcs-Svn: svn://svn.debian.org/pkg-voip/
@@ -11,7 +11,7 @@
Package: destar
Architecture: all
-Depends: python, ${python:Depends}, python-quixote1, python-medusa, asterisk (>= 1.2.13), python-pysqlite2, sqlite3, python-pychart
+Depends: python, ${python:Depends}, python-quixote1, python-medusa, asterisk (>= 1.2.13), python-pysqlite2, sqlite3, python-pychart, debconf
Recommends: op-panel
Conflicts: freepbx
XB-Python-Version: ${python:Versions}
Added: destar/trunk/debian/po/POTFILES.in
===================================================================
--- destar/trunk/debian/po/POTFILES.in (rev 0)
+++ destar/trunk/debian/po/POTFILES.in 2007-07-09 05:54:26 UTC (rev 3729)
@@ -0,0 +1 @@
+[type: gettext/rfc822deb] templates
Added: destar/trunk/debian/po/templates.pot
===================================================================
--- destar/trunk/debian/po/templates.pot (rev 0)
+++ destar/trunk/debian/po/templates.pot 2007-07-09 05:54:26 UTC (rev 3729)
@@ -0,0 +1,29 @@
+# SOME DESCRIPTIVE TITLE.
+# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
+# This file is distributed under the same license as the PACKAGE package.
+# FIRST AUTHOR <EMAIL at ADDRESS>, YEAR.
+#
+#, fuzzy
+msgid ""
+msgstr ""
+"Project-Id-Version: PACKAGE VERSION\n"
+"Report-Msgid-Bugs-To: pkg-voip-maintainers at lists.alioth.debian.org\n"
+"POT-Creation-Date: 2007-07-09 00:41-0500\n"
+"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
+"Last-Translator: FULL NAME <EMAIL at ADDRESS>\n"
+"Language-Team: LANGUAGE <LL at li.org>\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=CHARSET\n"
+"Content-Transfer-Encoding: 8bit\n"
+
+#. Type: string
+#. Description
+#: ../templates:1001
+msgid "DeStar listening port number:"
+msgstr ""
+
+#. Type: string
+#. Description
+#: ../templates:1001
+msgid "In which port, the web interface must listen on."
+msgstr ""
Modified: destar/trunk/debian/postinst
===================================================================
--- destar/trunk/debian/postinst 2007-07-08 17:36:49 UTC (rev 3728)
+++ destar/trunk/debian/postinst 2007-07-09 05:54:26 UTC (rev 3729)
@@ -17,6 +17,11 @@
# the debian-policy package
#
+. /usr/share/debconf/confmodule
+
+db_get destar/port
+port="$RET"
+
case "$1" in
configure)
# We use the asterisk user to run destar
@@ -40,6 +45,10 @@
--slave /etc/op-panel/op_astdb.cfg op-astdb-cfg /etc/op-panel/destar/op_astdb.cfg \
--slave /etc/op-panel/op_style.cfg op-style-cfg /etc/op-panel/destar/op_style.cfg
+ sed "s/^PORT=.*/PORT=$port/" /etc/default/destar > /etc/default/destar.tmp
+ mv /etc/default/destar.tmp /etc/default/destar
+
+ db_stop
;;
abort-upgrade|abort-remove|abort-deconfigure)
Modified: destar/trunk/debian/rules
===================================================================
--- destar/trunk/debian/rules 2007-07-08 17:36:49 UTC (rev 3728)
+++ destar/trunk/debian/rules 2007-07-09 05:54:26 UTC (rev 3729)
@@ -34,7 +34,7 @@
dh_testroot
rm -f build-stamp
- -$(MAKE) clean
+ [ ! -f Makefile ] || $(MAKE) clean
dh_clean
@@ -55,11 +55,11 @@
dh_installdocs
dh_installexamples
dh_installinit
+ dh_installdebconf
dh_link
dh_strip
dh_compress
dh_fixperms
- dh_python
dh_installdeb
dh_shlibdeps
dh_gencontrol
Added: destar/trunk/debian/templates
===================================================================
--- destar/trunk/debian/templates (rev 0)
+++ destar/trunk/debian/templates 2007-07-09 05:54:26 UTC (rev 3729)
@@ -0,0 +1,6 @@
+Template: destar/port
+Type: string
+Default: 8080
+_Description: DeStar listening port number:
+ In which port, the web interface must listen on.
+
More information about the Pkg-voip-commits
mailing list