bkruse: trunk r1728 - in /trunk: ./ scripts/editzap.sh

SVN commits to the Asterisk-GUI project asterisk-gui-commits at lists.digium.com
Wed Oct 24 16:07:50 CDT 2007


Author: bkruse
Date: Wed Oct 24 16:07:49 2007
New Revision: 1728

URL: http://svn.digium.com/view/asterisk-gui?view=rev&rev=1728
Log:
Merged revisions 1727 via svnmerge from 
https://origsvn.digium.com/svn/asterisk-gui/branches/1.4

........
r1727 | bkruse | 2007-10-24 16:06:17 -0500 (Wed, 24 Oct 2007) | 3 lines

changing so that editzap will now PRESERVE the settings
the gui writes for zapscan! I need to document this better.

........

Modified:
    trunk/   (props changed)
    trunk/scripts/editzap.sh

Propchange: trunk/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Modified: trunk/scripts/editzap.sh
URL: http://svn.digium.com/view/asterisk-gui/trunk/scripts/editzap.sh?view=diff&rev=1728&r1=1727&r2=1728
==============================================================================
--- trunk/scripts/editzap.sh (original)
+++ trunk/scripts/editzap.sh Wed Oct 24 16:07:49 2007
@@ -7,8 +7,11 @@
 # Quick script for applying zaptel settings from the GUI.
 
 ZAPCONF="/etc/zaptel.conf"
+ZAPATACONF="/etc/asterisk/zapata.conf"
 ZTCFG_OUTPUT="/var/lib/asterisk/static-http/config/ztcfg_output.html"
 FILENAME="/etc/asterisk/applyzap.conf"
+MISDNCONF="/etc/misdn-init.conf"
+MISDNFILE="/etc/asterisk/applymisdn.conf"
 
 case ${1} in
 	changemodes)
@@ -30,7 +33,15 @@
 		;;
 	applysettings)	
 		# Split based on ||| delimeter, and apply to zaptel.
-		grep -v "\[general\]" ${FILENAME} | grep -v "\;" > ${ZAPCONF} 
+		if [ "${2}" == "misdn" ]
+		then
+			grep -v "\[general\]" ${MISDNFILE} | grep -v "\;" > ${MISDNCONF}
+		else
+			grep -v "\[general\]" ${FILENAME} | grep -v "\;" > ${ZAPCONF} 
+			cp -rf ${ZAPCONF} ${ZAPCONF}.zapscan # save the gui settings!
+			cp -rf ${ZAPATACONF} ${ZAPATACONF}.zapscan # save the user settings
+			zapscan
+		fi
 		;;
 	ztcfg)
 		ztcfg -vv 2> $ZTCFG_OUTPUT




More information about the asterisk-gui-commits mailing list