diff --git a/bin/tools/RunFunctions b/bin/tools/RunFunctions index 1a040df6aa..1f21022b23 100644 --- a/bin/tools/RunFunctions +++ b/bin/tools/RunFunctions @@ -2,7 +2,7 @@ # ========= | # \\ / F ield | OpenFOAM: The Open Source CFD Toolbox # \\ / O peration | Website: https://openfoam.org -# \\ / A nd | Copyright (C) 2011-2021 OpenFOAM Foundation +# \\ / A nd | Copyright (C) 2011-2022 OpenFOAM Foundation # \\/ M anipulation | #------------------------------------------------------------------------------ # License @@ -49,6 +49,11 @@ getApplication() foamDictionary -entry application -value system/controlDict } +getSolver() +{ + foamDictionary -entry solver -value system/controlDict +} + runApplication() { APP_RUN= diff --git a/test/postProcessing/channel/Allclean b/test/postProcessing/channel/Allclean index 5f6a7899ea..1768db82db 100755 --- a/test/postProcessing/channel/Allclean +++ b/test/postProcessing/channel/Allclean @@ -1,6 +1,6 @@ #!/bin/sh -cd ${0%/*} || exit 1 +cd ${0%/*} || exit 1 # Run from this directory . $WM_PROJECT_DIR/bin/tools/CleanFunctions @@ -18,3 +18,5 @@ find 0 -mindepth 1 -maxdepth 1 \ ! -name T \ ! -name U \ -exec rm -rf {} \; + +#------------------------------------------------------------------------------ diff --git a/test/postProcessing/channel/Allrun b/test/postProcessing/channel/Allrun index be02715185..f695cbc11c 100755 --- a/test/postProcessing/channel/Allrun +++ b/test/postProcessing/channel/Allrun @@ -1,10 +1,12 @@ #!/bin/sh -cd ${0%/*} || exit 1 +cd ${0%/*} || exit 1 # Run from this directory . $WM_PROJECT_DIR/bin/tools/RunFunctions runApplication blockMesh runApplication topoSet runApplication $(getApplication) -runApplication foamPostProcess -solver fluid -latestTime +runApplication foamPostProcess -solver $(getSolver) -latestTime + +#------------------------------------------------------------------------------ diff --git a/tutorials/modules/incompressibleFluid/roomResidenceTime/Allrun b/tutorials/modules/incompressibleFluid/roomResidenceTime/Allrun index 412aebf301..923885b4a4 100755 --- a/tutorials/modules/incompressibleFluid/roomResidenceTime/Allrun +++ b/tutorials/modules/incompressibleFluid/roomResidenceTime/Allrun @@ -6,7 +6,7 @@ cd ${0%/*} || exit 1 # Run from this directory runApplication blockMesh runApplication foamRun -runApplication -s age foamPostProcess -solver incompressibleFluid -latestTime \ +runApplication -s age foamPostProcess -solver $(getSolver) -latestTime \ -func "age(diffusion=true)" runApplication -s probes1 foamPostProcess -func probes1 -latestTime runApplication -s probes2 foamPostProcess -func probes2 -latestTime