feat(third_party/bazel): Check in rules_haskell from Tweag

This commit is contained in:
Vincent Ambo 2019-07-04 11:18:12 +01:00
parent 2eb1dc26e4
commit f723b8b878
479 changed files with 51484 additions and 0 deletions

28
third_party/bazel/rules_haskell/serve-docs.sh vendored Executable file
View file

@ -0,0 +1,28 @@
#!/bin/sh
#
# Usage:
#
# ./serve-docs.sh [PORT_NUMBER]
set -e
SCRATCH=$(mktemp -d --tmpdir rules_haskell-docs.XXXX)
PORT=${1:-8000}
function finish {
echo Deleting $SCRATCH ...
rm -rf "$scratch"
}
trap finish EXIT
bazel build //docs:api_html
mkdir $SCRATCH/api
unzip -d $SCRATCH/api bazel-bin/docs/api_html-skydoc.zip
bazel build //docs:guide_html
mkdir $SCRATCH/guide
unzip -d $SCRATCH/guide bazel-genfiles/docs/guide_html.zip
cd $SCRATCH
python -m SimpleHTTPServer $PORT