Skip to content

Commit

Permalink
Look for zcat if there is no gzcat installed on the system
Browse files Browse the repository at this point in the history
  • Loading branch information
jafingerhut committed Nov 18, 2013
1 parent 1679e46 commit 49b79dc
Showing 1 changed file with 16 additions and 2 deletions.
18 changes: 16 additions & 2 deletions scripts/gen-most.sh
Original file line number Diff line number Diff line change
Expand Up @@ -314,7 +314,7 @@ esac

# After setting the values above, hopefully the rest of this can be common

set -x
set -ex

cd ${THALIA_TEMP_CHECKOUTS}
git clone ${GIT_URL}
Expand Down Expand Up @@ -349,5 +349,19 @@ fi
cd ..
#/bin/rm -fr ${GIT_REPO_ROOT_DIR_NAME}


# Mac OS X has gzcat, but at least some Ubuntu systems call it zcat.
if [ `which gzcat | wc -l` == "1" ]
then
GZCAT="gzcat"
elif [ `which zcat | wc -l` == "1" ]
then
GZCAT="zcat"
else
echo "No gzcat or zcat installed. Aborting."
exit 1
fi


cd ${THALIA_ROOT}
gzcat ${THALIA_CLOJUREDOCS_FILES_DIR}/${LEIN_CLOJUREDOCS_ROOT_FILE_NAME}.json.gz | lein run json2edn > ${THALIA_CLOJUREDOCS_FILES_DIR}/${LEIN_CLOJUREDOCS_ROOT_FILE_NAME}.clj
${GZCAT} ${THALIA_CLOJUREDOCS_FILES_DIR}/${LEIN_CLOJUREDOCS_ROOT_FILE_NAME}.json.gz | lein run json2edn > ${THALIA_CLOJUREDOCS_FILES_DIR}/${LEIN_CLOJUREDOCS_ROOT_FILE_NAME}.clj

0 comments on commit 49b79dc

Please sign in to comment.