summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRyota MIBU <r-mibu@cq.jp.nec.com>2016-01-07 11:55:45 +0900
committerRyota Mibu <r-mibu@cq.jp.nec.com>2016-01-07 09:09:16 +0000
commit8bb24cb8235c1158f9fa0339e997526a651c4f86 (patch)
treea6b264ce22e726cbc2de9ce7be9d08b9b793d073
parent9a3df319ebb2dfc7328b5a66e3e6cf69ebe0413e (diff)
docs-build.sh: fix merging of top level docs
Change-Id: I6d489be3631fa81e799b55cce9d9e3d1c2608140 Signed-off-by: Ryota MIBU <r-mibu@cq.jp.nec.com>
-rwxr-xr-xutils/docs-build.sh11
1 files changed, 10 insertions, 1 deletions
diff --git a/utils/docs-build.sh b/utils/docs-build.sh
index e5e602584..914eaf207 100755
--- a/utils/docs-build.sh
+++ b/utils/docs-build.sh
@@ -180,7 +180,16 @@ do
}
if is_top_dir "$dir" ; then
- mv "$output"/* "$OUTPUT_DIR"/
+ # NOTE: Having top level document (docs/index.rst) is not recommended.
+ # It may cause conflicts with other docs (mostly with HTML
+ # folders for contents in top level docs and other document
+ # folders). But, let's try merge of those contents into the top
+ # docs directory.
+ (
+ cd $output
+ find . -type d -print | xargs -I d mkdir -p ../d
+ find . -type f -print | xargs -I f mv -b f ../f
+ )
rm -rf "$output"
fi