Commit 9fc85e51 authored by peguerin's avatar peguerin
Browse files

reset results folder

parent 6a5603c3
###############################################################################
MODE=$1
if [ -d "results" ]; then
if [ "$MODE" == "clear" ]; then
echo -n "Clearing..."
......@@ -15,6 +11,8 @@ if [ -d "results" ]; then
mkdir results/04_filter_samples/01_dereplicated results/04_filter_samples/02_goodlength results/04_filter_samples/03_clean_pcrerr results/04_filter_samples/04_filtered
mkdir results/05_assignment/01_runs results/05_assignment/02_dereplicated results/05_assignment/03_assigned results/05_assignment/04_formated
echo "done"
echo "Previous result files are now stored into 'cleared' folder."
echo "A new folder 'results' with empty subfolders have been created."
elif [ "$MODE" == "reset" ]; then
echo -n "Resetting..."
rm -r results
......@@ -25,8 +23,11 @@ if [ -d "results" ]; then
mkdir results/04_filter_samples/01_dereplicated results/04_filter_samples/02_goodlength results/04_filter_samples/03_clean_pcrerr results/04_filter_samples/04_filtered
mkdir results/05_assignment/01_runs results/05_assignment/02_dereplicated results/05_assignment/03_assigned results/05_assignment/04_formated
echo "done"
echo "Previous result files have been removed."
echo "A new folder 'results' with empty subfolders have been created."
else
echo -n "You must set an action to perform:\n bash clean.sh clear "
printf "clean.sh don't work because you didn't set an action to perform as first argument:\n$ bash clean.sh clear\n move current result folder into a folder named 'cleared' and create again a new folder result\n$ bash clean.sh reset\n remove current result folder and create a new folder results\n"
fi
else
echo "Cleaning is impossible... you are not in the right folder."
fi
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment