Skip to content

Commit 5289e5b

Browse files
committed
fix cache directory remove
1 parent 8e3c47d commit 5289e5b

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

bin/reloadFixtures.sh

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,11 @@ run () {
2121
}
2222

2323
CACHE_DIR=${DIR}var/cache/prod
24-
#run "Remove cache directory:" "rm -rf ${CACHE_DIR}"
24+
if [ -d "${CACHE_DIR}" ]; then
25+
run "Remove cache directory:" "rm -rf ${CACHE_DIR}"
26+
else
27+
run "Remove cache directory:" "rm -rf /var/cache/prod"
28+
fi
2529
run "Drop and init dbal:" "php ${DIR}bin/console --env=prod doctrine:phpcr:init:dbal --drop --force -n -vvv"
2630
run "Init repositories:" "php ${DIR}bin/console --env=prod doctrine:phpcr:repository:init -n -vvv"
2731
run "Load date fixtures:" "php ${DIR}bin/console --env=prod doctrine:phpcr:fixtures:load -n -vvv"

0 commit comments

Comments
 (0)