aboutsummaryrefslogtreecommitdiffstats
path: root/resources/libraries/bash
diff options
context:
space:
mode:
authorViliam Luc <vluc@cisco.com>2021-09-28 19:46:36 +0200
committerPeter Mikus <pmikus@cisco.com>2021-10-20 09:30:48 +0000
commit7089e466dfdcc58ebad94ce5fe65ddbbb8b78925 (patch)
treed4b9fd62898996758d552a463e35cf5abd4dbe02 /resources/libraries/bash
parent4775366636f137998d7f878cfa0f75f658ae01de (diff)
doc gen: fix doc generator
Change-Id: I75e836ce728fd333764f17d69813093cb947ef4f Signed-off-by: Viliam Luc <vluc@cisco.com>
Diffstat (limited to 'resources/libraries/bash')
-rw-r--r--resources/libraries/bash/function/docs.sh22
1 files changed, 9 insertions, 13 deletions
diff --git a/resources/libraries/bash/function/docs.sh b/resources/libraries/bash/function/docs.sh
index be3f9861ce..c589416a37 100644
--- a/resources/libraries/bash/function/docs.sh
+++ b/resources/libraries/bash/function/docs.sh
@@ -47,12 +47,13 @@ function generate_docs () {
pushd "${TOOLS_DIR}"/doc_gen || die "Pushd failed!"
- WORKING_DIR="tmp"
BUILD_DIR="_build"
# Remove the old build:
rm -rf ${BUILD_DIR} || true
- rm -rf ${WORKING_DIR} || true
+ rm -rf /tmp/tmp-csit* || true
+
+ export WORKING_DIR=$(mktemp -d /tmp/tmp-csitXXX) || die "export failed"
# Create working directories
mkdir -p "${BUILD_DIR}" || die "Mkdir failed!"
@@ -81,17 +82,12 @@ function generate_docs () {
die "Touch index.robot file failed!"
}
- # Due to hoststack tests having dots in the name of suite, tests will become
- # disabled as spihnxdoc cannot properly work with the path. gen_rst
- # is generating dots scheme. The solution is to rename suites as
- # having dots is misleading with robot framework naming conventions.
-
- #from_dir="${CSIT_DIR}/tests/"
- #to_dir="${WORKING_DIR}/tests/"
- #dirs="${from_dir} ${to_dir}"
- #rsync -ar --include='*/' --include '*.robot' --exclude '*' ${dirs} || {
- # die "rSync failed!"
- #}
+ from_dir="${CSIT_DIR}/tests/"
+ to_dir="${WORKING_DIR}/tests/"
+ dirs="${from_dir} ${to_dir}"
+ rsync -ar --include='*/' --include '*.robot' --exclude '*' ${dirs} || {
+ die "rSync failed!"
+ }
find ${WORKING_DIR}/ -type d -exec echo {} \; -exec touch {}/__init__.py \;