[Update] Save git diff only when local changes exist (#3350)
parent
6152042d3e
commit
3c7b8dc447
|
@ -370,8 +370,10 @@ DIFF_FILE=${DIFF_DIRECTORY}/diff_before_update_$(date +"%Y-%m-%d-%H-%M-%S")
|
||||||
echo -e "\e[32mSaving diff to ${DIFF_FILE}...\e[0m"
|
echo -e "\e[32mSaving diff to ${DIFF_FILE}...\e[0m"
|
||||||
mkdir -p ${DIFF_DIRECTORY}
|
mkdir -p ${DIFF_DIRECTORY}
|
||||||
mv diff_before_update* ${DIFF_DIRECTORY}/ 2> /dev/null
|
mv diff_before_update* ${DIFF_DIRECTORY}/ 2> /dev/null
|
||||||
git diff --stat > ${DIFF_FILE}
|
if ! git diff-index --quiet HEAD; then
|
||||||
git diff >> ${DIFF_FILE}
|
git diff --stat > ${DIFF_FILE}
|
||||||
|
git diff >> ${DIFF_FILE}
|
||||||
|
fi
|
||||||
|
|
||||||
echo -e "\e[32mPrefetching images...\e[0m"
|
echo -e "\e[32mPrefetching images...\e[0m"
|
||||||
prefetch_images
|
prefetch_images
|
||||||
|
|
Loading…
Reference in New Issue