From e451dad94e9db50c23395ebf5162fce0fde46e13 Mon Sep 17 00:00:00 2001 From: Akkadius Date: Tue, 10 Mar 2020 19:42:52 -0500 Subject: [PATCH] Dump tweaks [skip ci] --- utils/sql/peq-dump/peq-dump.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/utils/sql/peq-dump/peq-dump.sh b/utils/sql/peq-dump/peq-dump.sh index 911439c8f..ccb7b8949 100755 --- a/utils/sql/peq-dump/peq-dump.sh +++ b/utils/sql/peq-dump/peq-dump.sh @@ -21,7 +21,8 @@ echo "World path is [$world_path] bin is [$world_bin]" dump_path=/tmp/peq-dump/ echo "Generating dump path [${dump_path}]" -rm -rf ${dump_path} && mkdir -p ${dump_path} +rm -rf ${dump_path} +mkdir -p ${dump_path} ############################################# # generate "drop_" table files @@ -61,7 +62,7 @@ bash -c "cd ${dump_path} && ls * | grep drop | sed 's/.*/source &;/' > drop_all_ human_date=$(date +"%B-%d-%Y" | tr '[:upper:]' '[:lower:]') echo "Compressing..." -bash -c "cd /tmp/ && rm peq-latest.zip && zip peq-latest.zip peq-dump/* && mv ${dump_path}peq-latest.zip /tmp/peq-latest.zip" +bash -c "cd /tmp/ && rm -rf peq-latest.zip && zip peq-latest.zip peq-dump/* && mv ${dump_path}peq-latest.zip /tmp/peq-latest.zip" echo "Cleaning up..." rm -rf ${dump_path}