Skip to content
Snippets Groups Projects
Commit e569b408 authored by Oriol Tintó's avatar Oriol Tintó
Browse files

Fix clean template.

parent 7abd1c67
No related branches found
No related tags found
1 merge request!3Refactor folder structure. Putting configuration files and namelists inside...
...@@ -5,19 +5,18 @@ WORKDIR=%HPCROOTDIR% ...@@ -5,19 +5,18 @@ WORKDIR=%HPCROOTDIR%
STARTDATE=%SDATE% STARTDATE=%SDATE%
MEMBER=%MEMBER% MEMBER=%MEMBER%
FILES_TO_CLEAN='%simulation.FILES_TO_CLEAN%' FILES_TO_CLEAN='%simulation.FILES_TO_CLEAN%'
echo "${FILES_TO_CLEAN}" echo "${FILES_TO_CLEAN}"
# Define run directory # Define run directory
RUNDIR=${WORKDIR}/${STARTDATE}/${MEMBER} RUNDIR=${WORKDIR}/${STARTDATE}/${MEMBER}
# Copy the output files cd ${RUNDIR} || exit
for file_name in "${FILES_TO_CLEAN}"; do # Remove the files in the run directory
echo "Removing:" ${file_name} rm ${FILES_TO_CLEAN}
rm "${RUNDIR}/${file_name}"
done
# Remove the output files from the remote machine # Remove the files in the remote output directory
OUTPUT_DIR=${WORKDIR}/output/${STARTDATE}/${MEMBER} OUTPUT_DIR=${WORKDIR}/output/${STARTDATE}/${MEMBER}
rm ${OUTPUT_DIR}/* cd ${OUTPUT_DIR} || exit
rm ${FILES_TO_CLEAN}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment