Reset build dir in script before run

Fixes #515 which isn't really a bug, but can occasionally cause
confusion when switching environments for the app
main
Ben Busby 2021-11-01 16:20:22 -06:00
parent d1c9b7f803
commit 829903fb9c
No known key found for this signature in database
GPG Key ID: 339B7B7EB5333D14
1 changed files with 4 additions and 0 deletions

4
run
View File

@ -12,6 +12,10 @@ SUBDIR="${1:-app}"
export APP_ROOT="$SCRIPT_DIR/$SUBDIR" export APP_ROOT="$SCRIPT_DIR/$SUBDIR"
export STATIC_FOLDER="$APP_ROOT/static" export STATIC_FOLDER="$APP_ROOT/static"
# Clear out build directory
rm -f "$SCRIPT_DIR"/app/static/build/*.js
rm -f "$SCRIPT_DIR"/app/static/build/*.css
# Check for regular vs test run # Check for regular vs test run
if [[ "$SUBDIR" == "test" ]]; then if [[ "$SUBDIR" == "test" ]]; then
# Set up static files for testing # Set up static files for testing