From 6403ca4e67e718a898f3ccde901a06c1823576db Mon Sep 17 00:00:00 2001 From: "clara.bayley" Date: Sun, 17 Nov 2024 20:40:17 +0100 Subject: [PATCH] refactor: require path2CLEO is set in bash --- examples/slurm_allexamples.sh | 29 +++++++++++++++++------------ 1 file changed, 17 insertions(+), 12 deletions(-) diff --git a/examples/slurm_allexamples.sh b/examples/slurm_allexamples.sh index 85b47088..e75fc48e 100755 --- a/examples/slurm_allexamples.sh +++ b/examples/slurm_allexamples.sh @@ -13,15 +13,20 @@ path2CLEO=$1 -sbatch ${path2CLEO}/examples/adiabaticparcel/as2017.sh -sbatch ${path2CLEO}/examples/adiabaticparcel/cuspbifurc.sh -sbatch ${path2CLEO}/examples/boxmodelcollisions/shima2009.sh -sbatch ${path2CLEO}/examples/boxmodelcollisions/breakup.sh -#sbatch ${path2CLEO}/examples/bubble3d/bubble3d.sh # TODO(CB): complete -sbatch ${path2CLEO}/examples/constthermo2d/constthermo2d.sh -sbatch ${path2CLEO}/examples/divfreemotion/divfree2d.sh -sbatch ${path2CLEO}/examples/eurec4a1d/eurec4a1d.sh -sbatch ${path2CLEO}/examples/fromfile/fromfile.sh -sbatch ${path2CLEO}/examples/fromfile_irreg/fromfile_irreg.sh -sbatch ${path2CLEO}/examples/rainshaft1d/rainshaft1d.sh -sbatch ${path2CLEO}/examples/speedtest/speedtest.sh +if [ -z "${path2CLEO}" ]; +then + echo "please specify the path2CLEO" +else + sbatch ${path2CLEO}/examples/adiabaticparcel/as2017.sh + sbatch ${path2CLEO}/examples/adiabaticparcel/cuspbifurc.sh + sbatch ${path2CLEO}/examples/boxmodelcollisions/shima2009.sh + sbatch ${path2CLEO}/examples/boxmodelcollisions/breakup.sh + #sbatch ${path2CLEO}/examples/bubble3d/bubble3d.sh # TODO(CB): complete + sbatch ${path2CLEO}/examples/constthermo2d/constthermo2d.sh + sbatch ${path2CLEO}/examples/divfreemotion/divfree2d.sh + sbatch ${path2CLEO}/examples/eurec4a1d/eurec4a1d.sh + sbatch ${path2CLEO}/examples/fromfile/fromfile.sh + sbatch ${path2CLEO}/examples/fromfile_irreg/fromfile_irreg.sh + sbatch ${path2CLEO}/examples/rainshaft1d/rainshaft1d.sh + sbatch ${path2CLEO}/examples/speedtest/speedtest.sh +fi