From 155a6cf2a345d759dfe239672993ffbab3f9536b Mon Sep 17 00:00:00 2001
From: Michael <m.langguth@fz-juelich.de>
Date: Mon, 18 Jul 2022 15:40:28 +0200
Subject: [PATCH] Bugfix in setup_runscript_templates.sh to ensure clean copy
 of general runscript template.

---
 .../utils/runscript_generator/setup_runscript_templates.sh    | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/video_prediction_tools/utils/runscript_generator/setup_runscript_templates.sh b/video_prediction_tools/utils/runscript_generator/setup_runscript_templates.sh
index a398fc6e..b684069a 100755
--- a/video_prediction_tools/utils/runscript_generator/setup_runscript_templates.sh
+++ b/video_prediction_tools/utils/runscript_generator/setup_runscript_templates.sh
@@ -49,7 +49,7 @@ fi
 echo "Start setting up templates under HPC_scripts/..."
 for f in "${BASE_DIR}"/HPC_scripts/*template.sh; do
   echo "Setting up ${f}..."
-  fnew=${f%%.*}_${USER}.sh
+  fnew=${f%.*}_${USER}.sh
   cp "${f}" "${fnew}"
   sed -i "s|\(.*_dir=\).*|\1${data_dir}|g" "${fnew}"
 done
@@ -58,7 +58,7 @@ echo "Done!"
 echo "Start setting up templates under no_HPC_scripts/"
 for f in "${BASE_DIR}"/no_HPC_scripts/*template.sh; do
   echo "Setting up ${f}..."
-  fnew=${f%%.*}_${USER}.sh
+  fnew=${f%.*}_${USER}.sh
   cp "${f}" "${fnew}"
   sed -i "s|\(.*_dir=\).*|\1${data_dir}|g" "${fnew}"
 done
-- 
GitLab