[evolvis-commits] r9983: Renaming *.php in DATE*. php↵

mirabilos at evolvis.org mirabilos at evolvis.org
Thu Feb 24 17:35:13 CET 2011


Author: mirabilos
Date: 2011-02-24 17:35:13 +0100 (Thu, 24 Feb 2011)
New Revision: 9983

Added:
   trunk/gforge_base/evolvisforge-5.1/gforge/db/20040826_migrateforum.php
   trunk/gforge_base/evolvisforge-5.1/gforge/db/20040826_migraterbac.php
Removed:
   trunk/gforge_base/evolvisforge-5.1/gforge/db/migrateforum.php
   trunk/gforge_base/evolvisforge-5.1/gforge/db/migraterbac.php
Log:
Renaming *.php in DATE*.php


Added: trunk/gforge_base/evolvisforge-5.1/gforge/db/20040826_migrateforum.php
===================================================================
--- trunk/gforge_base/evolvisforge-5.1/gforge/db/20040826_migrateforum.php	                        (rev 0)
+++ trunk/gforge_base/evolvisforge-5.1/gforge/db/20040826_migrateforum.php	2011-02-24 16:35:13 UTC (rev 9983)
@@ -0,0 +1,56 @@
+#! /usr/bin/php4 -f
+<?php
+/**
+ * GForge Forum Renamer - forum names are now unix-format for email gateway
+ *
+ * Copyright 2004 GForge, LLC
+ * http://gforge.org/
+ *
+ * @version   $Id$
+ *
+ * This file is part of GForge.
+ *
+ * GForge is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * GForge is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with GForge; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  US
+ */
+
+require_once('www/include/squal_pre.php');
+
+//
+//	Convert forum names to new legal syntax
+//
+db_begin();
+$res=db_query("SELECT group_forum_id,forum_name FROM forum_group_list");
+echo db_error();
+
+for ($i=0; $i<db_numrows($res); $i++) {
+
+	$sql="UPDATE forum_group_list 
+		SET forum_name='". ereg_replace('[^_\.0-9a-z-]','-', strtolower(db_result($res,$i,'forum_name')) )."' 
+		WHERE group_forum_id='".db_result($res,$i,'group_forum_id')."'";
+	$res2=db_query($sql);
+	echo db_error();
+
+}
+
+//
+//	Long-standing oddity in GForge - 
+//	forums were ZERO-pen Discussion, not Oh-pen Discussion
+//
+db_query("UPDATE forum_group_list SET forum_name='open-discussion' 
+	WHERE forum_name='0pen-discussion'");
+
+db_commit();
+
+?>


Property changes on: trunk/gforge_base/evolvisforge-5.1/gforge/db/20040826_migrateforum.php
___________________________________________________________________
Added: svn:executable
   + *

Added: trunk/gforge_base/evolvisforge-5.1/gforge/db/20040826_migraterbac.php
===================================================================
--- trunk/gforge_base/evolvisforge-5.1/gforge/db/20040826_migraterbac.php	                        (rev 0)
+++ trunk/gforge_base/evolvisforge-5.1/gforge/db/20040826_migraterbac.php	2011-02-24 16:35:13 UTC (rev 9983)
@@ -0,0 +1,68 @@
+#! /usr/bin/php4 -f
+<?php
+/**
+ * GForge Group Role Generator
+ *
+ * Copyright 2004 GForge, LLC
+ * http://gforge.org/
+ *
+ * @version   $Id$
+ *
+ * This file is part of GForge.
+ *
+ * GForge is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * GForge is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with GForge; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  US
+ */
+
+require_once('www/include/squal_pre.php');
+require_once('common/include/Role.class');
+
+//
+//	Set up this script to run as the site admin
+//
+$id=db_result(db_query("SELECT user_id FROM user_group WHERE admin_flags='A' AND group_id='1'"),0,0);
+session_set_new($id);
+
+//
+//	Clear out role settings in case this was run before
+//
+db_begin();
+db_query("UPDATE user_group SET role_id=1");
+db_query("DELETE FROM role_setting");
+db_query("DELETE FROM role WHERE role_id>1");
+
+$res=db_query("SELECT group_id FROM groups WHERE status != 'P'");
+$arr = util_result_column_to_array($res);
+
+for ($i=0; $i<count($arr); $i++) {
+	$g =& group_get_object($arr[$i]);
+	//
+	//
+	//  Set Default Roles
+	//
+	//
+	$role = new Role($g);
+	$todo = array_keys($role->defaults);
+	for ($c=0; $c<count($todo); $c++) {
+		$role = new Role($g);
+		if (!$role->createDefault($todo[$c])) {
+			$this->setError($role->getErrorMessage());
+			db_rollback();
+			echo "Could Not Create Default Roles: ".$arr[$i];
+		}
+	}
+}
+db_commit();
+
+?>


Property changes on: trunk/gforge_base/evolvisforge-5.1/gforge/db/20040826_migraterbac.php
___________________________________________________________________
Added: svn:executable
   + *

Deleted: trunk/gforge_base/evolvisforge-5.1/gforge/db/migrateforum.php
===================================================================
--- trunk/gforge_base/evolvisforge-5.1/gforge/db/migrateforum.php	2011-02-24 16:35:11 UTC (rev 9982)
+++ trunk/gforge_base/evolvisforge-5.1/gforge/db/migrateforum.php	2011-02-24 16:35:13 UTC (rev 9983)
@@ -1,56 +0,0 @@
-#! /usr/bin/php4 -f
-<?php
-/**
- * GForge Forum Renamer - forum names are now unix-format for email gateway
- *
- * Copyright 2004 GForge, LLC
- * http://gforge.org/
- *
- * @version   $Id$
- *
- * This file is part of GForge.
- *
- * GForge is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * GForge is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with GForge; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  US
- */
-
-require_once('www/include/squal_pre.php');
-
-//
-//	Convert forum names to new legal syntax
-//
-db_begin();
-$res=db_query("SELECT group_forum_id,forum_name FROM forum_group_list");
-echo db_error();
-
-for ($i=0; $i<db_numrows($res); $i++) {
-
-	$sql="UPDATE forum_group_list 
-		SET forum_name='". ereg_replace('[^_\.0-9a-z-]','-', strtolower(db_result($res,$i,'forum_name')) )."' 
-		WHERE group_forum_id='".db_result($res,$i,'group_forum_id')."'";
-	$res2=db_query($sql);
-	echo db_error();
-
-}
-
-//
-//	Long-standing oddity in GForge - 
-//	forums were ZERO-pen Discussion, not Oh-pen Discussion
-//
-db_query("UPDATE forum_group_list SET forum_name='open-discussion' 
-	WHERE forum_name='0pen-discussion'");
-
-db_commit();
-
-?>

Deleted: trunk/gforge_base/evolvisforge-5.1/gforge/db/migraterbac.php
===================================================================
--- trunk/gforge_base/evolvisforge-5.1/gforge/db/migraterbac.php	2011-02-24 16:35:11 UTC (rev 9982)
+++ trunk/gforge_base/evolvisforge-5.1/gforge/db/migraterbac.php	2011-02-24 16:35:13 UTC (rev 9983)
@@ -1,68 +0,0 @@
-#! /usr/bin/php4 -f
-<?php
-/**
- * GForge Group Role Generator
- *
- * Copyright 2004 GForge, LLC
- * http://gforge.org/
- *
- * @version   $Id$
- *
- * This file is part of GForge.
- *
- * GForge is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * GForge is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with GForge; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  US
- */
-
-require_once('www/include/squal_pre.php');
-require_once('common/include/Role.class');
-
-//
-//	Set up this script to run as the site admin
-//
-$id=db_result(db_query("SELECT user_id FROM user_group WHERE admin_flags='A' AND group_id='1'"),0,0);
-session_set_new($id);
-
-//
-//	Clear out role settings in case this was run before
-//
-db_begin();
-db_query("UPDATE user_group SET role_id=1");
-db_query("DELETE FROM role_setting");
-db_query("DELETE FROM role WHERE role_id>1");
-
-$res=db_query("SELECT group_id FROM groups WHERE status != 'P'");
-$arr = util_result_column_to_array($res);
-
-for ($i=0; $i<count($arr); $i++) {
-	$g =& group_get_object($arr[$i]);
-	//
-	//
-	//  Set Default Roles
-	//
-	//
-	$role = new Role($g);
-	$todo = array_keys($role->defaults);
-	for ($c=0; $c<count($todo); $c++) {
-		$role = new Role($g);
-		if (!$role->createDefault($todo[$c])) {
-			$this->setError($role->getErrorMessage());
-			db_rollback();
-			echo "Could Not Create Default Roles: ".$arr[$i];
-		}
-	}
-}
-db_commit();
-
-?>



More information about the evolvis-commits mailing list