From dc677124c6ac2110c26dc8de14381f9d86e17bf9 Mon Sep 17 00:00:00 2001 From: Sergio Benitez Date: Sun, 2 Oct 2016 17:29:59 -0700 Subject: [PATCH] Add script to build docs. --- scripts/mk-docs.sh | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100755 scripts/mk-docs.sh diff --git a/scripts/mk-docs.sh b/scripts/mk-docs.sh new file mode 100755 index 00000000..ffd29e5d --- /dev/null +++ b/scripts/mk-docs.sh @@ -0,0 +1,22 @@ +#!/bin/bash +set -e + +# +# Builds the rustdocs for all of the libraries. +# + +# Brings in: EXAMPLES_DIR, LIB_DIR, CODEGEN_DIR, and CONTRIB_DIR, DOC_DIR +SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +source $SCRIPT_DIR/config.sh + +function mk_doc() { + local dir=$1 + pushd $dir > /dev/null + echo ":: Documenting '${dir}'..." + cargo doc --no-deps --all-features + popd > /dev/null +} + +mk_doc $LIB_DIR +mk_doc $CODEGEN_DIR +mk_doc $CONTRIB_DIR