[Fusionforge-commits] r9609 - in trunk: gforge/common/include gforge/cronjobs/mail gforge/www/pm gforge/www/reporting gforge/www/scm/reporting gforge/www/survey/admin gforge/www/tracker/reporting tests/code/deprecations

Roland Mas lolando at libremir.placard.fr.eu.org
Tue Apr 27 21:14:53 CEST 2010


Author: lolando
Date: 2010-04-27 21:14:53 +0200 (Tue, 27 Apr 2010)
New Revision: 9609

Modified:
   trunk/gforge/common/include/config-vars.php
   trunk/gforge/common/include/utils.php
   trunk/gforge/cronjobs/mail/mailing_lists_create.php
   trunk/gforge/www/pm/gantt.php
   trunk/gforge/www/pm/ganttofuser.php
   trunk/gforge/www/reporting/groupadded_graph.php
   trunk/gforge/www/reporting/groupcum_graph.php
   trunk/gforge/www/reporting/projectact_graph.php
   trunk/gforge/www/reporting/projecttime_graph.php
   trunk/gforge/www/reporting/siteact_graph.php
   trunk/gforge/www/reporting/sitetime_graph.php
   trunk/gforge/www/reporting/sitetimebar_graph.php
   trunk/gforge/www/reporting/toolspie_graph.php
   trunk/gforge/www/reporting/trackerpie_graph.php
   trunk/gforge/www/reporting/useract_graph.php
   trunk/gforge/www/reporting/useradded_graph.php
   trunk/gforge/www/reporting/usercum_graph.php
   trunk/gforge/www/reporting/usertime_graph.php
   trunk/gforge/www/scm/reporting/commits_graph.php
   trunk/gforge/www/scm/reporting/commitstime_graph.php
   trunk/gforge/www/survey/admin/graphs.php
   trunk/gforge/www/tracker/reporting/trackeract_graph.php
   trunk/gforge/www/tracker/reporting/trackerpie_graph.php
   trunk/tests/code/deprecations/DeprecationsTest.php
Log:
Config API: path to some pieces of software

Modified: trunk/gforge/common/include/config-vars.php
===================================================================
--- trunk/gforge/common/include/config-vars.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/common/include/config-vars.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -79,6 +79,9 @@
 forge_define_config_item ('stats_group', 'core', $GLOBALS['sys_stats_group']) ;
 forge_define_config_item ('peer_rating_group', 'core', $GLOBALS['sys_peer_rating_group']) ;
 forge_define_config_item ('template_group', 'core', $GLOBALS['sys_template_group']) ;
+forge_define_config_item ('sendmail_path', 'core', $GLOBALS['sys_sendmail_path']) ;
+forge_define_config_item ('mailman_path', 'core', $GLOBALS['sys_path_to_mailman']) ;
+forge_define_config_item ('jpgraph_path', 'core', $GLOBALS['sys_path_to_jpgraph']) ;
 // forge_define_config_item ('', 'core', $GLOBALS['sys_']) ;
 
 /* Long-term:

Modified: trunk/gforge/common/include/utils.php
===================================================================
--- trunk/gforge/common/include/utils.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/common/include/utils.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -129,8 +129,8 @@
  *
  */
 function util_send_message($to,$subject,$body,$from='',$BCC='',$sendername='',$extra_headers='',$send_html_email=false) {
-	global $sys_sendmail_path;
 
+
 	if (!$to) {
 		$to='noreply@'.forge_get_config('web_host');
 	}
@@ -162,11 +162,11 @@
 		"\n\n".
 		util_convert_body($body, $charset);
 	
-	if (!$sys_sendmail_path){
+	if (!forge_get_config('sendmail_path')){
 		$sys_sendmail_path="/usr/sbin/sendmail";
 	}
 
- 	$handle = popen($sys_sendmail_path." -f'$from' -t -i", 'w');
+ 	$handle = popen(forge_get_config('sendmail_path')." -f'$from' -t -i", 'w');
 	fwrite ($handle, $body2);
  	pclose($handle);
 }

Modified: trunk/gforge/cronjobs/mail/mailing_lists_create.php
===================================================================
--- trunk/gforge/cronjobs/mail/mailing_lists_create.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/cronjobs/mail/mailing_lists_create.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -13,7 +13,7 @@
 
 $err = '';
 
-if (is_dir($sys_path_to_mailman)) {
+if (is_dir(forge_get_config('mailman_path'))) {
 } elseif (is_dir("/usr/lib/mailman")) {
 	$sys_path_to_mailman="/usr/lib/mailman";
 } else {
@@ -26,7 +26,7 @@
 // already exist
 //
 $mailing_lists=array();
-$mlists_cmd = escapeshellcmd($sys_path_to_mailman."/bin/list_lists");
+$mlists_cmd = escapeshellcmd(forge_get_config('mailman_path')."/bin/list_lists");
 $err .= "Command to be executed is $mlists_cmd\n";
 $fp = popen ($mlists_cmd,"r");
 while (!feof($fp)) {
@@ -70,13 +70,13 @@
 	
 	// Here we assume that the privatize_list.py script is located in the same dir as this script
 	$script_dir = dirname(__FILE__);
-	$privatize_cmd = escapeshellcmd($sys_path_to_mailman.'/bin/config_list -i '.$script_dir.'/privatize_list.py '.$listname);
-	$publicize_cmd = escapeshellcmd($sys_path_to_mailman.'/bin/config_list -i '.$script_dir.'/publicize_list.py '.$listname);
+	$privatize_cmd = escapeshellcmd(forge_get_config('mailman_path').'/bin/config_list -i '.$script_dir.'/privatize_list.py '.$listname);
+	$publicize_cmd = escapeshellcmd(forge_get_config('mailman_path').'/bin/config_list -i '.$script_dir.'/publicize_list.py '.$listname);
 	
 	if (! in_array($listname,$mailing_lists)) {		// New list?
 		$err .= "Creating Mailing List: $listname\n";
-		//$lcreate_cmd = $sys_path_to_mailman."/bin/newlist -q $listname@".forge_get_config('lists_host')." $email $listpassword &> /dev/null";
-		$lcreate_cmd = $sys_path_to_mailman."/bin/newlist -q $listname $email $listpassword";
+		//$lcreate_cmd = forge_get_config('mailman_path')."/bin/newlist -q $listname@".forge_get_config('lists_host')." $email $listpassword &> /dev/null";
+		$lcreate_cmd = forge_get_config('mailman_path')."/bin/newlist -q $listname $email $listpassword";
 		$err .= "Command to be executed is $lcreate_cmd\n";
 		passthru($lcreate_cmd, $failed);
 		if($failed) {
@@ -97,26 +97,26 @@
 		}
 	}
 	
-	if(file_exists($sys_path_to_mailman.'/mail/mailman')) {
+	if(file_exists(forge_get_config('mailman_path').'/mail/mailman')) {
 		// Mailman 2.1
 		$list_str =
-$listname.':              "|'.$sys_path_to_mailman.'/mail/mailman post '.$listname.'"'."\n"
-.$listname.'-admin:        "|'.$sys_path_to_mailman.'/mail/mailman admin '.$listname.'"'."\n"
-.$listname.'-bounces:      "|'.$sys_path_to_mailman.'/mail/mailman bounces '.$listname.'"'."\n"
-.$listname.'-confirm:      "|'.$sys_path_to_mailman.'/mail/mailman confirm '.$listname.'"'."\n"
-.$listname.'-join:         "|'.$sys_path_to_mailman.'/mail/mailman join '.$listname.'"'."\n"
-.$listname.'-leave:        "|'.$sys_path_to_mailman.'/mail/mailman leave '.$listname.'"'."\n"
-.$listname.'-owner:        "|'.$sys_path_to_mailman.'/mail/mailman owner '.$listname.'"'."\n"
-.$listname.'-request:      "|'.$sys_path_to_mailman.'/mail/mailman request '.$listname.'"'."\n"
-.$listname.'-subscribe:    "|'.$sys_path_to_mailman.'/mail/mailman subscribe '.$listname.'"'."\n"
-.$listname.'-unsubscribe:  "|'.$sys_path_to_mailman.'/mail/mailman unsubscribe '.$listname.'"'."\n\n"
+$listname.':              "|'.forge_get_config('mailman_path').'/mail/mailman post '.$listname.'"'."\n"
+.$listname.'-admin:        "|'.forge_get_config('mailman_path').'/mail/mailman admin '.$listname.'"'."\n"
+.$listname.'-bounces:      "|'.forge_get_config('mailman_path').'/mail/mailman bounces '.$listname.'"'."\n"
+.$listname.'-confirm:      "|'.forge_get_config('mailman_path').'/mail/mailman confirm '.$listname.'"'."\n"
+.$listname.'-join:         "|'.forge_get_config('mailman_path').'/mail/mailman join '.$listname.'"'."\n"
+.$listname.'-leave:        "|'.forge_get_config('mailman_path').'/mail/mailman leave '.$listname.'"'."\n"
+.$listname.'-owner:        "|'.forge_get_config('mailman_path').'/mail/mailman owner '.$listname.'"'."\n"
+.$listname.'-request:      "|'.forge_get_config('mailman_path').'/mail/mailman request '.$listname.'"'."\n"
+.$listname.'-subscribe:    "|'.forge_get_config('mailman_path').'/mail/mailman subscribe '.$listname.'"'."\n"
+.$listname.'-unsubscribe:  "|'.forge_get_config('mailman_path').'/mail/mailman unsubscribe '.$listname.'"'."\n\n"
 ;
 	} else {
 		// Mailman < 2.1
 		$list_str =
-$listname.':		"|'.$sys_path_to_mailman.'/mail/wrapper post '.$listname.'"'."\n"
-.$listname.'-admin:	"|'.$sys_path_to_mailman.'/mail/wrapper mailowner '.$listname.'"'."\n"
-.$listname.'-request:	"|'.$sys_path_to_mailman.'/mail/wrapper mailcmd '.$listname.'"'."\n"
+$listname.':		"|'.forge_get_config('mailman_path').'/mail/wrapper post '.$listname.'"'."\n"
+.$listname.'-admin:	"|'.forge_get_config('mailman_path').'/mail/wrapper mailowner '.$listname.'"'."\n"
+.$listname.'-request:	"|'.forge_get_config('mailman_path').'/mail/wrapper mailcmd '.$listname.'"'."\n"
 .$listname.'-owner:	'.$listname.'-admin'."\n\n";
 	}
 
@@ -144,7 +144,7 @@
 for($k = 0; $k < $rows; $k++) {
 	$deleted_mail_list = db_result($res,$k,'mailing_list_name');
 	
-	exec($sys_path_to_mailman."/bin/rmlist -a $deleted_mail_list", $output);
+	exec(forge_get_config('mailman_path')."/bin/rmlist -a $deleted_mail_list", $output);
 	$success = false;
 	foreach ($output as $line) {
 		// Mailman 2.1.x

Modified: trunk/gforge/www/pm/gantt.php
===================================================================
--- trunk/gforge/www/pm/gantt.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/www/pm/gantt.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -1,11 +1,11 @@
 <?php
 
-if (!file_exists($sys_path_to_jpgraph.'/jpgraph.php')) {
+if (!file_exists(forge_get_config('jpgraph_path').'/jpgraph.php')) {
 	exit_error('Error', 'Package JPGraph not installed');
 }
 
-require_once($sys_path_to_jpgraph.'/jpgraph.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_gantt.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_gantt.php');
 require_once $gfcommon.'pm/ProjectTaskFactory.class.php';
 require_once $gfwww.'include/unicode.php';
 

Modified: trunk/gforge/www/pm/ganttofuser.php
===================================================================
--- trunk/gforge/www/pm/ganttofuser.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/www/pm/ganttofuser.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -2,12 +2,12 @@
 
 require_once('../env.inc.php');
 require_once $gfwww.'include/pre.php';
-require_once($sys_path_to_jpgraph.'/jpgraph.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_gantt.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_gantt.php');
 require_once $gfcommon.'pm/ProjectTasksForUser.class.php';
 
 
-if (!file_exists($sys_path_to_jpgraph.'/jpgraph.php')) {
+if (!file_exists(forge_get_config('jpgraph_path').'/jpgraph.php')) {
 	exit_error('Error', 'Package JPGraph not installed');
 }
 

Modified: trunk/gforge/www/reporting/groupadded_graph.php
===================================================================
--- trunk/gforge/www/reporting/groupadded_graph.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/www/reporting/groupadded_graph.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -26,8 +26,8 @@
 
 require_once('../env.inc.php');
 require_once $gfwww.'include/pre.php';
-require_once($sys_path_to_jpgraph.'/jpgraph.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_line.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_line.php');
 require_once $gfcommon.'reporting/ReportGroupAdded.class.php';
 
 session_require( array('group'=>forge_get_config('stats_group')) );

Modified: trunk/gforge/www/reporting/groupcum_graph.php
===================================================================
--- trunk/gforge/www/reporting/groupcum_graph.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/www/reporting/groupcum_graph.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -26,8 +26,8 @@
 
 require_once('../env.inc.php');
 require_once $gfwww.'include/pre.php';
-require_once($sys_path_to_jpgraph.'/jpgraph.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_line.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_line.php');
 require_once $gfcommon.'reporting/ReportGroupCum.class.php';
 
 session_require( array('group'=>forge_get_config('stats_group')) );

Modified: trunk/gforge/www/reporting/projectact_graph.php
===================================================================
--- trunk/gforge/www/reporting/projectact_graph.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/www/reporting/projectact_graph.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -26,8 +26,8 @@
 
 require_once('../env.inc.php');
 require_once $gfwww.'include/pre.php';
-require_once($sys_path_to_jpgraph.'/jpgraph.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_line.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_line.php');
 require_once $gfcommon.'reporting/ReportProjectAct.class.php';
 require_once $gfwww.'include/unicode.php';
 

Modified: trunk/gforge/www/reporting/projecttime_graph.php
===================================================================
--- trunk/gforge/www/reporting/projecttime_graph.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/www/reporting/projecttime_graph.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -26,9 +26,9 @@
 
 require_once('../env.inc.php');
 require_once $gfwww.'include/pre.php';
-require_once($sys_path_to_jpgraph.'/jpgraph.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_pie.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_pie3d.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_pie.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_pie3d.php');
 require_once $gfcommon.'reporting/ReportProjectTime.class.php';
 require_once $gfcommon.'reporting/report_utils.php';
 

Modified: trunk/gforge/www/reporting/siteact_graph.php
===================================================================
--- trunk/gforge/www/reporting/siteact_graph.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/www/reporting/siteact_graph.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -26,8 +26,8 @@
 
 require_once('../env.inc.php');
 require_once $gfwww.'include/pre.php';
-require_once($sys_path_to_jpgraph.'/jpgraph.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_line.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_line.php');
 require_once $gfcommon.'reporting/ReportSiteAct.class.php';
 require_once $gfwww.'include/unicode.php';
 

Modified: trunk/gforge/www/reporting/sitetime_graph.php
===================================================================
--- trunk/gforge/www/reporting/sitetime_graph.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/www/reporting/sitetime_graph.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -26,9 +26,9 @@
 
 require_once('../env.inc.php');
 require_once $gfwww.'include/pre.php';
-require_once($sys_path_to_jpgraph.'/jpgraph.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_pie.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_pie3d.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_pie.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_pie3d.php');
 require_once $gfcommon.'reporting/ReportSiteTime.class.php';
 require_once $gfcommon.'reporting/report_utils.php';
 

Modified: trunk/gforge/www/reporting/sitetimebar_graph.php
===================================================================
--- trunk/gforge/www/reporting/sitetimebar_graph.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/www/reporting/sitetimebar_graph.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -26,8 +26,8 @@
 
 require_once('../env.inc.php');
 require_once $gfwww.'include/pre.php';
-require_once($sys_path_to_jpgraph.'/jpgraph.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_bar.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_bar.php');
 require_once $gfcommon.'reporting/Report.class.php';
 
 session_require( array('group'=>forge_get_config('stats_group')) );

Modified: trunk/gforge/www/reporting/toolspie_graph.php
===================================================================
--- trunk/gforge/www/reporting/toolspie_graph.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/www/reporting/toolspie_graph.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -26,9 +26,9 @@
 
 require_once('../env.inc.php');
 require_once $gfwww.'include/pre.php';
-require_once($sys_path_to_jpgraph.'/jpgraph.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_pie.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_pie3d.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_pie.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_pie3d.php');
 require_once $gfcommon.'reporting/Report.class.php';
 require_once $gfcommon.'reporting/report_utils.php';
 

Modified: trunk/gforge/www/reporting/trackerpie_graph.php
===================================================================
--- trunk/gforge/www/reporting/trackerpie_graph.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/www/reporting/trackerpie_graph.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -26,9 +26,9 @@
 
 require_once('../env.inc.php');
 require_once $gfwww.'include/pre.php';
-require_once($sys_path_to_jpgraph.'/jpgraph.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_pie.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_pie3d.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_pie.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_pie3d.php');
 require_once $gfcommon.'reporting/Report.class.php';
 require_once $gfcommon.'reporting/report_utils.php';
 require_once $gfwww.'tracker/include/ArtifactTypeHtml.class.php';

Modified: trunk/gforge/www/reporting/useract_graph.php
===================================================================
--- trunk/gforge/www/reporting/useract_graph.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/www/reporting/useract_graph.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -26,8 +26,8 @@
 
 require_once('../env.inc.php');
 require_once $gfwww.'include/pre.php';
-require_once($sys_path_to_jpgraph.'/jpgraph.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_line.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_line.php');
 require_once $gfcommon.'reporting/ReportUserAct.class.php';
 require_once $gfwww.'include/unicode.php';
 

Modified: trunk/gforge/www/reporting/useradded_graph.php
===================================================================
--- trunk/gforge/www/reporting/useradded_graph.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/www/reporting/useradded_graph.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -26,8 +26,8 @@
 
 require_once('../env.inc.php');
 require_once $gfwww.'include/pre.php';
-require_once($sys_path_to_jpgraph.'/jpgraph.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_line.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_line.php');
 require_once $gfcommon.'reporting/ReportUserAdded.class.php';
 
 session_require( array('group'=>forge_get_config('stats_group')) );

Modified: trunk/gforge/www/reporting/usercum_graph.php
===================================================================
--- trunk/gforge/www/reporting/usercum_graph.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/www/reporting/usercum_graph.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -26,8 +26,8 @@
 
 require_once('../env.inc.php');
 require_once $gfwww.'include/pre.php';
-require_once($sys_path_to_jpgraph.'/jpgraph.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_line.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_line.php');
 require_once $gfcommon.'reporting/ReportUserCum.class.php';
 
 session_require( array('group'=>forge_get_config('stats_group')) );

Modified: trunk/gforge/www/reporting/usertime_graph.php
===================================================================
--- trunk/gforge/www/reporting/usertime_graph.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/www/reporting/usertime_graph.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -26,9 +26,9 @@
 
 require_once('../env.inc.php');
 require_once $gfwww.'include/pre.php';
-require_once($sys_path_to_jpgraph.'/jpgraph.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_pie.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_pie3d.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_pie.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_pie3d.php');
 require_once $gfcommon.'reporting/ReportUserTime.class.php';
 require_once $gfcommon.'reporting/report_utils.php';
 

Modified: trunk/gforge/www/scm/reporting/commits_graph.php
===================================================================
--- trunk/gforge/www/scm/reporting/commits_graph.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/www/scm/reporting/commits_graph.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -26,9 +26,9 @@
 
 require_once('../../env.inc.php');
 require_once $gfwww.'include/pre.php';
-require_once($sys_path_to_jpgraph.'/jpgraph.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_pie.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_pie3d.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_pie.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_pie3d.php');
 require_once $gfcommon.'reporting/Report.class.php';
 require_once $gfcommon.'reporting/report_utils.php';
 

Modified: trunk/gforge/www/scm/reporting/commitstime_graph.php
===================================================================
--- trunk/gforge/www/scm/reporting/commitstime_graph.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/www/scm/reporting/commitstime_graph.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -26,8 +26,8 @@
 
 require_once('../../env.inc.php');
 require_once $gfwww.'include/pre.php';
-require_once($sys_path_to_jpgraph.'/jpgraph.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_line.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_line.php');
 require_once $gfcommon.'reporting/ReportUserAdded.class.php';
 
 //

Modified: trunk/gforge/www/survey/admin/graphs.php
===================================================================
--- trunk/gforge/www/survey/admin/graphs.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/www/survey/admin/graphs.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -21,17 +21,17 @@
 require_once $gfwww.'include/pre.php';
 
 // Check if we have jpgraph
-if (!file_exists($sys_path_to_jpgraph.'/jpgraph.php')) {
+if (!file_exists(forge_get_config('jpgraph_path').'/jpgraph.php')) {
     //# TODO: Need to show the message as a image file
     exit_error('Error', 'Package JPGraph not installed');
 }
 
-// Read jPGraph libraries. Make sure the $sys_path_to_jpgraph is correct in local.inc
-require_once $sys_path_to_jpgraph.'/jpgraph.php';
-require_once $sys_path_to_jpgraph.'/jpgraph_line.php';
-require_once $sys_path_to_jpgraph.'/jpgraph_bar.php';
-require_once $sys_path_to_jpgraph.'/jpgraph_pie.php';
-require_once $sys_path_to_jpgraph.'/jpgraph_pie3d.php';
+// Read jPGraph libraries. Make sure the forge_get_config('jpgraph_path') is correct in local.inc
+require_once forge_get_config('jpgraph_path').'/jpgraph.php';
+require_once forge_get_config('jpgraph_path').'/jpgraph_line.php';
+require_once forge_get_config('jpgraph_path').'/jpgraph_bar.php';
+require_once forge_get_config('jpgraph_path').'/jpgraph_pie.php';
+require_once forge_get_config('jpgraph_path').'/jpgraph_pie3d.php';
 
 $type = getStringFromRequest('type');
 $legend = getStringFromRequest('legend');

Modified: trunk/gforge/www/tracker/reporting/trackeract_graph.php
===================================================================
--- trunk/gforge/www/tracker/reporting/trackeract_graph.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/www/tracker/reporting/trackeract_graph.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -26,8 +26,8 @@
 
 require_once('../../env.inc.php');
 require_once $gfwww.'include/pre.php';
-require_once($sys_path_to_jpgraph.'/jpgraph.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_line.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_line.php');
 require_once $gfcommon.'reporting/ReportTrackerAct.class.php';
 
 $group_id = getIntFromRequest('group_id');

Modified: trunk/gforge/www/tracker/reporting/trackerpie_graph.php
===================================================================
--- trunk/gforge/www/tracker/reporting/trackerpie_graph.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/gforge/www/tracker/reporting/trackerpie_graph.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -26,9 +26,9 @@
 
 require_once('../../env.inc.php');
 require_once $gfwww.'include/pre.php';
-require_once($sys_path_to_jpgraph.'/jpgraph.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_pie.php');
-require_once($sys_path_to_jpgraph.'/jpgraph_pie3d.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_pie.php');
+require_once(forge_get_config('jpgraph_path').'/jpgraph_pie3d.php');
 require_once $gfcommon.'reporting/Report.class.php';
 require_once $gfcommon.'reporting/report_utils.php';
 require_once $gfwww.'tracker/include/ArtifactTypeHtml.class.php';

Modified: trunk/tests/code/deprecations/DeprecationsTest.php
===================================================================
--- trunk/tests/code/deprecations/DeprecationsTest.php	2010-04-27 19:05:29 UTC (rev 9608)
+++ trunk/tests/code/deprecations/DeprecationsTest.php	2010-04-27 19:14:53 UTC (rev 9609)
@@ -96,6 +96,9 @@
 			       'sys_stats_group',
 			       'sys_peer_rating_group',
 			       'sys_template_group',
+			       'sys_sendmail_path',
+			       'sys_path_to_mailman',
+			       'sys_path_to_jpgraph',
 			) ;
 
 		$pattern = implode ('|', $vars) ;




More information about the Fusionforge-commits mailing list