Commit 44052de5 authored by Mark Olesen's avatar Mark Olesen

TUT: skip some tutorials when dynamicCode is not available

- silence failed restoration of controlDict from controlDict.orig
  (idempotent?)
parent 9ef14411
......@@ -23,6 +23,10 @@ foamDictionary -help > /dev/null 2>&1 || {
}
# Some tests may need #calc
unset noDynamicCode
canCompile || noDynamicCode=true
for dict in \
good*.dict \
warn*.dict \
......@@ -31,6 +35,11 @@ for dict in \
do
[ -f "$dict" ] || continue # protect against bad globs
if [ "$noDynamicCode" = true ] && grep -q '#calc' "$dict"
then
continue
fi
# capture stderr, ignore stdout
stderr=$(foamDictionary -keywords $dict 2>&1 >/dev/null)
exitCode=$?
......
......@@ -3,6 +3,8 @@ cd "${0%/*}" || exit # Run from this directory
. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions
#------------------------------------------------------------------------------
canCompile || exit 0 # Dynamic code
restore0Dir
runApplication blockMesh
runApplication $(getApplication) -withFunctionObjects -writePhi -writep
......
#!/bin/sh
cd "${0%/*}" || exit # Run from this directory
. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions
#------------------------------------------------------------------------------
canCompile || exit 0 # Dynamic code
runApplication blockMesh
runApplication $(getApplication)
#------------------------------------------------------------------------------
......@@ -3,6 +3,8 @@ cd "${0%/*}" || exit # Run from this directory
. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions
#------------------------------------------------------------------------------
canCompile || exit 0 # Dynamic code
runApplication kivaToFoam -file otape17
runApplication $(getApplication)
......
......@@ -3,6 +3,8 @@ cd "${0%/*}" || exit # Run from this directory
. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions
#------------------------------------------------------------------------------
canCompile || exit 0 # Dynamic code
./Allrun.pre
# Serial
......
......@@ -3,6 +3,8 @@ cd "${0%/*}" || exit # Run from this directory
. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions
#------------------------------------------------------------------------------
canCompile || exit 0 # Dynamic code
restore0Dir
runApplication blockMesh
runApplication -s preProcess $(getApplication) -postProcess -dict system/preProcess
......
......@@ -3,6 +3,8 @@ cd "${0%/*}" || exit # Run from this directory
. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions
#------------------------------------------------------------------------------
canCompile || exit 0 # Dynamic code
echo "Use common files for 0/, constant/ and blockMeshDict"
rm -rf 0 constant
\cp -r ../common/0.orig 0
......
......@@ -3,6 +3,8 @@ cd "${0%/*}" || exit # Run from this directory
. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions
#------------------------------------------------------------------------------
canCompile || exit 0 # Dynamic code
runApplication blockMesh
runApplication topoSet
......
......@@ -3,6 +3,8 @@ cd "${0%/*}" || exit # Run from this directory
. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions
#------------------------------------------------------------------------------
canCompile || exit 0 # Dynamic code
echo "Linking processor*/ directory"
for proc in $(\ls -d ../steadyState/processor*)
do
......
......@@ -3,6 +3,8 @@ cd "${0%/*}" || exit # Run from this directory
. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions
#------------------------------------------------------------------------------
canCompile || exit 0 # Dynamic code
./Allrun.pre
runApplication decomposePar
......
......@@ -4,6 +4,8 @@ cd "${0%/*}" || exit # Run from this directory
. ${WM_PROJECT_DIR:?}/bin/tools/CleanFunctions # Tutorial clean functions
#------------------------------------------------------------------------------
canCompile || exit 0 # Dynamic code
runApplication blockMesh
# Turbulence closure models
......
......@@ -3,6 +3,8 @@ cd "${0%/*}" || exit # Run from this directory
. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions
#------------------------------------------------------------------------------
canCompile || exit 0 # Dynamic code
runApplication blockMesh
runApplication topoSet
runApplication refineHexMesh c0 -overwrite
......
#!/bin/sh
cd "${0%/*}" || exit # Run from this directory
. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions
#------------------------------------------------------------------------------
canCompile || exit 0 # Dynamic code
runApplication blockMesh
runApplication $(getApplication)
#------------------------------------------------------------------------------
......@@ -3,6 +3,8 @@ cd "${0%/*}" || exit # Run from this directory
. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions
#------------------------------------------------------------------------------
canCompile || exit 0 # Dynamic code
restore0Dir
runApplication blockMesh
......
......@@ -3,6 +3,8 @@ cd "${0%/*}" || exit # Run from this directory
. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions
#------------------------------------------------------------------------------
canCompile || exit 0 # Dynamic code
runApplication blockMesh
runApplication topoSet
runApplication subsetMesh -overwrite c0 -patch floatingObject
......
#!/bin/sh
cd "${0%/*}" || exit # Run from this directory
. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions
#------------------------------------------------------------------------------
canCompile || exit 0 # Dynamic code
runApplication blockMesh
runApplication $(getApplication)
#------------------------------------------------------------------------------
......@@ -3,6 +3,8 @@ cd "${0%/*}" || exit # Run from this directory
. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions
#------------------------------------------------------------------------------
canCompile || exit 0 # Dynamic code
# Create background mesh
runApplication blockMesh
......
......@@ -3,6 +3,8 @@ cd "${0%/*}" || exit # Run from this directory
. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions
#------------------------------------------------------------------------------
canCompile || exit 0 # Dynamic code
./Allrun.pre
# Serial
......
......@@ -8,7 +8,7 @@ cleanCase0
if notTest $@
then
mv -f system/controlDict.orig system/controlDict
mv -f system/controlDict.orig system/controlDict 2>/dev/null
fi
#------------------------------------------------------------------------------
......@@ -8,7 +8,7 @@ cleanCase0
if notTest $@
then
mv -f system/controlDict.orig system/controlDict
mv -f system/controlDict.orig system/controlDict 2>/dev/null
fi
#------------------------------------------------------------------------------
......@@ -8,7 +8,7 @@ cleanCase0
if notTest $@
then
mv -f system/controlDict.orig system/controlDict
mv -f system/controlDict.orig system/controlDict 2>/dev/null
fi
#------------------------------------------------------------------------------
......@@ -8,7 +8,7 @@ cleanCase0
if notTest $@
then
mv -f system/controlDict.orig system/controlDict
mv -f system/controlDict.orig system/controlDict 2>/dev/null
fi
#------------------------------------------------------------------------------
......@@ -8,7 +8,7 @@ cleanCase0
if notTest $@
then
mv -f system/controlDict.orig system/controlDict
mv -f system/controlDict.orig system/controlDict 2>/dev/null
fi
#------------------------------------------------------------------------------
......@@ -3,6 +3,8 @@ cd "${0%/*}" || exit # Run from this directory
. ${WM_PROJECT_DIR:?}/bin/tools/RunFunctions # Tutorial run functions
#------------------------------------------------------------------------------
canCompile || exit 0 # Dynamic code
restore0Dir
runApplication blockMesh
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment