#!/bin/sh
cd "${0%/*}" || exit                                # Run from this directory
#------------------------------------------------------------------------------

# Removes everything a run produces, and keeps the mesh and 0.orig.
# The mesh goes with 'rm -rf constant/polyMesh', 0.orig with git checkout.

rm -rf 0 warmup processor* postProcessing dynamicCode log.* logs

for d in [0-9]*; do
    case "$d" in
        0.orig | 0.scratch) continue ;;
    esac
    [ -d "$d" ] && rm -rf "$d"
done
#------------------------------------------------------------------------------
