#!/usr/bin/env bash # ------------------------------------------------------------------------------ # Build the Sphinx documentation. # # Examples: # ./build.sh # ./build.sh --name my-documentation # ------------------------------------------------------------------------------ PROJECT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )/.." && pwd )" # shellcheck disable=SC1090 source "${PROJECT_DIR}/bin/shflags/shflags" # shellcheck disable=SC1090 source "${PROJECT_DIR}/bin/ansi/ansi" # shellcheck disable=SC1090 source "${PROJECT_DIR}/bin/ndd-log4b/ndd-log4b.sh" # shellcheck disable=SC1090 source "${PROJECT_DIR}/bin/ndd-utils4b/ndd-utils4b.sh" # shellcheck disable=SC1090 source "${PROJECT_DIR}/bin/variables.sh" # disable before shflags ndd::base::catch_more_errors_off DEFINE_string "name" "${DDIDIER_SPHINX_CONTAINER_NAME}" "The name of the container" "n" DEFINE_boolean "pdf" false "Enable PDF gneration" "p" DEFINE_boolean "debug" false "Enable debug mode" "d" read -r -d '' FLAGS_HELP <&1)" exit 1 } trap 'error_handler ${?}' ERR main "${@}" exit 0