[SCM] Gerris Flow Solver branch, upstream, updated. b3aa46814a06c9cb2912790b23916ffb44f1f203

Stephane Popinet popinet at users.sf.net
Fri May 15 02:52:27 UTC 2009


The following commit has been merged in the upstream branch:
commit 8d5ae95a35e17180942b42bcb08fa818c6f56de4
Author: Stephane Popinet <popinet at users.sf.net>
Date:   Wed Aug 10 19:40:52 2005 +1000

    Bug fix for environment variables in gfs2tex
    
    darcs-hash:20050810094052-d4795-a717b6a4a8c6e984aee9280899e260f7f7745c35.gz

diff --git a/doc/examples/gfs2tex.py b/doc/examples/gfs2tex.py
index 2e1460c..bcc916b 100644
--- a/doc/examples/gfs2tex.py
+++ b/doc/examples/gfs2tex.py
@@ -229,13 +229,9 @@ class Example:
         else:
             return None,None
 
-    def run(self,env=None):
-        if env:
-            env += " && "
-        else:
-            env = ""
-        out = os.popen("cd " + self.path + " && " +\
-                       "sh -c \"time -p " + env + self.command + "\" 2>&1")
+    def run(self,env=""):
+        out = os.popen("cd " + self.path + " && ( time -p " + env +\
+                       " sh -c \"" + self.command + "\" ) 2>&1")
         lines = []
         for l in out:
             record = l.split()
diff --git a/test/euler/test.py b/test/euler/test.py
index 49de31a..2605604 100644
--- a/test/euler/test.py
+++ b/test/euler/test.py
@@ -6,7 +6,7 @@ sys.path.append("../../doc/examples")
 import gfs2tex
 from datetime import *
 
-env = "export PYTHONPATH=$PYTHONPATH:" + os.getcwd() + " && export donotrun=false"
+env = "PYTHONPATH=$PYTHONPATH:" + os.getcwd() + " donotrun=false"
 system = commands.getoutput('uname -o -n -m')
 path = commands.getoutput('which gerris2D')
 version = commands.getoutput("""gerris2D -V 2>&1 | awk '{if ($5 == "version") print $6;}'""")

-- 
Gerris Flow Solver



More information about the debian-science-commits mailing list