From a98dc51d3fe3138e3d5007f3141eb0c3aacc7d5f Mon Sep 17 00:00:00 2001 From: Gautham Pai Date: Fri, 30 Dec 2011 02:44:46 +0530 Subject: Fix hang on `make doc` when earlier attempt fails Fixing the issue where the script hangs forever when a previous make had failed and the script is re-run. --- scripts/doc-build.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'scripts') diff --git a/scripts/doc-build.sh b/scripts/doc-build.sh index 6c32ea183..d1ece59f6 100755 --- a/scripts/doc-build.sh +++ b/scripts/doc-build.sh @@ -7,7 +7,7 @@ set -o errexit set -o pipefail if ! [ -x node_modules/.bin/ronn ]; then - if [ -f .building_ronn ]; then + if [ -f .building_ronn -a $(ps --no-headers -p $(cat .building_ronn) 2> /dev/null | wc -l) != 0 ]; then while [ -f .building_ronn ]; do sleep 1 done @@ -68,4 +68,4 @@ case $dest in echo "Invalid destination type: $dest" >&2 exit 1 ;; -esac +esac \ No newline at end of file -- cgit v1.2.3