adds directory testing before file moves (bugfix for move errors when git does not clone an empty existing directory)

This commit is contained in:
Chris Simpkins 2017-08-29 23:17:46 -04:00
parent 8895e7e949
commit 14f8d41f32
4 changed files with 30 additions and 1 deletions

View File

@ -166,6 +166,11 @@ fi
#
# ////////////////////////////////////////////////
# cleanup any previously created temp directory that was not removed
if ! [ -d "$TEMP_SOURCE" ]; then
rm -rf $TEMP_SOURCE
fi
# create temp directory for subset source files
mkdir $TEMP_SOURCE
@ -394,6 +399,11 @@ fi
#
# //////////////////////////////////////////////
# create the build directory if it does not exist
if ! [ -d "$WEB_BUILD" ]; then
mkdir $WEB_BUILD
fi
echo " "
echo "Moving woff files to build directory..."

View File

@ -203,6 +203,13 @@ echo " "
# Move release files to build directory
echo " "
# create directory if it does not exist
# (occurs with git + empty directories)
if ! [ -d build/ttf ]; then
mkdir build/ttf
fi
mv master_ttf/hinted/Hack-Regular.ttf build/ttf/Hack-Regular.ttf
echo "Regular ttf build path: build/ttf/Hack-Regular.ttf"
mv master_ttf/hinted/Hack-Italic.ttf build/ttf/Hack-Italic.ttf

View File

@ -136,6 +136,12 @@ fi
echo "Moving woff files to build directory..."
# create directory if it does not exist
# (occurs with git + empty directories)
if ! [ -d "$WOFF_BUILD" ]; then
mkdir $WOFF_BUILD
fi
# move woff files to appropriate build directory
mv "$TTF_BUILD/$REGULAR_PRE" "$WOFF_BUILD/$REGULAR_WOFF"
mv "$TTF_BUILD/$BOLD_PRE" "$WOFF_BUILD/$BOLD_WOFF"

View File

@ -128,7 +128,13 @@ fi
echo "Moving woff2 files to build directory..."
# move woff files to appropriate build directory
# create directory if it does not exist
# (occurs with git + empty directories)
if ! [ -d "$WOFF_BUILD" ]; then
mkdir $WOFF_BUILD
fi
# move woff2 files to appropriate build directory
mv "$TTF_BUILD/$REGULAR_PRE" "$WOFF_BUILD/$REGULAR_WOFF"
mv "$TTF_BUILD/$BOLD_PRE" "$WOFF_BUILD/$BOLD_WOFF"
mv "$TTF_BUILD/$ITALIC_PRE" "$WOFF_BUILD/$ITALIC_WOFF"