[icinga-checkins] icinga.org: icinga-web/mhein/extlayout: * Removed critical bug in remove-module script

git at icinga.org git at icinga.org
Tue May 11 19:18:12 CEST 2010


Module: icinga-web
Branch: mhein/extlayout
Commit: 3bf7f1372a340a67d7afe0e93127b9086bc18b8c
URL:    https://git.icinga.org/?p=icinga-web.git;a=commit;h=3bf7f1372a340a67d7afe0e93127b9086bc18b8c

Author: jmosshammer <jannis.mosshammer at netways.de>
Date:   Tue May 11 16:24:32 2010 +0200

* Removed critical bug in remove-module script

---

 modules/bin/doctrineDBBuilderTask.php |    2 +-
 modules/bin/fileSelectorTask.php      |    4 +++-
 modules/bin/sqlRunnerTask.php         |    4 ++--
 modules/build.xml                     |    7 ++++---
 4 files changed, 10 insertions(+), 7 deletions(-)

diff --git a/modules/bin/doctrineDBBuilderTask.php b/modules/bin/doctrineDBBuilderTask.php
index c79e95c..2c5bd70 100755
--- a/modules/bin/doctrineDBBuilderTask.php
+++ b/modules/bin/doctrineDBBuilderTask.php
@@ -9,7 +9,7 @@ class doctrineDBBuilderTask extends Task {
 	protected $models;
 	protected $action;
 	protected $ini;
-	
+	static protected $AppKitPath = null;
 	public function init() {
 		
 	}
diff --git a/modules/bin/fileSelectorTask.php b/modules/bin/fileSelectorTask.php
index 72b9320..95f87dd 100755
--- a/modules/bin/fileSelectorTask.php
+++ b/modules/bin/fileSelectorTask.php
@@ -90,7 +90,9 @@ class fileSelectorTask extends Task {
 		$icingaPath = $this->project->getUserProperty("PATH_Icinga");
 		$coreDir = $this->project->getUserProperty("coreDir");
 		$fileset->setDir($icingaPath);
-		$includes = $this->getPath($coreDir)."/**";
+		$includes ="";
+		if($this->getPath($coreDir))
+			$includes = $this->getPath($coreDir)."/**";
 		$excludes = "";
 		foreach($files->Excludes->children() as $type=>$address) {
 			if($excludes != "")
diff --git a/modules/bin/sqlRunnerTask.php b/modules/bin/sqlRunnerTask.php
index b2ed2bb..6f865c3 100755
--- a/modules/bin/sqlRunnerTask.php
+++ b/modules/bin/sqlRunnerTask.php
@@ -49,8 +49,8 @@ class sqlRunnerTask extends Task {
 		$doctrine = Doctrine_Manager::getInstance()->getCurrentConnection()->getDbh();
 		$files = scandir($this->files);
 		foreach($files as $filename) {
-			if(substr($fileName,-3,3) == 'sql') {
-				$sql = file_get_contents($filename);
+			if(substr($filename,-3) == 'sql') {
+				$sql = file_get_contents($this->files."/".$filename);
 				$doctrine->query($sql);
 			}
 		}
diff --git a/modules/build.xml b/modules/build.xml
index 86be571..8466a67 100755
--- a/modules/build.xml
+++ b/modules/build.xml
@@ -250,11 +250,12 @@ Available targets:
 			Finally remove files
 		 -->
 		<echo>Removing files</echo>
-		<delete dir="${PATH_Icinga}/app/modules/${MODULE_Name}" />	
+		<delete dir="${PATH_Icinga}/app/modules/${MODULE_Name}" />
+	
 		<fileSelector refid="manifest" source="Module" propertyName="module"/>
 		<delete>
-			<fileset refid="module" />
-		</delete>
+			<fileset refid="module"/>
+		</delete>		
 		
 		<echo>Clearing cache</echo>
 		<delete dir="${PATH_Icinga}/app/cache/config" />





More information about the icinga-checkins mailing list