Skip to content

Commit

Permalink
Fixed website-build.sh nighlty to tag renames.
Browse files Browse the repository at this point in the history
  • Loading branch information
ylussaud committed Sep 11, 2024
1 parent 6f3d3fb commit 058470e
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion scripts/website-build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,11 @@ echo "Build gh-pages"
mkdir ../plugins/org.obeonetwork.m2doc.doc/doc
# download the nighlty documentation
echo " - Download nightly documentation"
wget -r --no-parent --no-host-directories --no-verbose -P ../plugins/org.obeonetwork.m2doc.doc/doc/ https://www.m2doc.org/ref-doc/nightly/
wget -r --no-parent --no-host-directories --no-verbose -P ../plugins/org.obeonetwork.m2doc.doc/doc/ https://www.m2doc.org/ref-doc/ /
# replace nigthly by current tag
if [ -n "$TAG" ]; then
echo " - Replace Nightly to" $TAG
mv ../plugins/org.obeonetwork.m2doc.doc/doc/nightly ../plugins/org.obeonetwork.m2doc.doc/doc/$TAG
find ../plugins/org.obeonetwork.m2doc.doc/doc/ -name "*.html" -exec sed -i 's#Nightly#'$TAG'#g' {} \;
find ../plugins/org.obeonetwork.m2doc.doc/doc/ -name "*.html" -exec sed -i 's#nightly#'$TAG'#g' {} \;
fi
Expand All @@ -30,5 +31,8 @@ cp -R images ../plugins/org.obeonetwork.m2doc.doc/doc/
cp -R capella ../plugins/org.obeonetwork.m2doc.doc/doc/
cp -R font-awesome ../plugins/org.obeonetwork.m2doc.doc/doc/
cp ref-doc/index-toc.xml ../plugins/org.obeonetwork.m2doc.doc/doc/ref-doc/index-toc.xml
if [ -n "$TAG" ]; then
find ../plugins/org.obeonetwork.m2doc.doc/doc/ -name "index-toc.xml" -exec sed -i 's#nightly#'$TAG'#g' {} \;
fi
cd -

0 comments on commit 058470e

Please sign in to comment.