]> granicus.if.org Git - esp-idf/commitdiff
Adjusted CI configuration to handle 'en' and 'zh_CN' language versions
authorkrzychb <krzychb@gazeta.pl>
Sat, 3 Feb 2018 21:12:13 +0000 (22:12 +0100)
committerkrzychb <krzychb@gazeta.pl>
Tue, 13 Mar 2018 21:07:31 +0000 (22:07 +0100)
.gitlab-ci.yml
docs/check_doc_warnings.sh

index 09711b6b75129c64903f3088eaef3246f2a5bf74..f39858304733f57ffc5c3347f709b3ab1b3c7a7c 100644 (file)
@@ -196,19 +196,26 @@ build_docs:
   artifacts:
     when: always
     paths:
-      - docs/doxygen-warning-log.txt
-      - docs/sphinx-warning-log.txt
-      - docs/sphinx-warning-log-sanitized.txt
-      - docs/_build/html
+      # English version of documentation
+      - docs/en/doxygen-warning-log.txt
+      - docs/en/sphinx-warning-log.txt
+      - docs/en/sphinx-warning-log-sanitized.txt
+      - docs/en/_build/html
+      # Chinese version of documentation
+      - docs/zh_CN/doxygen-warning-log.txt
+      - docs/zh_CN/sphinx-warning-log.txt
+      - docs/zh_CN/sphinx-warning-log-sanitized.txt
+      - docs/zh_CN/_build/html
     expire_in: 1 mos
   script:
-    - cd docs
-    - doxygen
-    # If there are Doxygen warnings, print them and bail out
-    - test $(cat doxygen-warning-log.txt | wc -l) -eq 0 || ( echo "Doxygen pass had some warnings:" && cat doxygen-warning-log.txt && false )
+    - cd docs/en
+    - make gh-linkcheck
+    - make html
+    - ../check_doc_warnings.sh
+    - cd ../zh_CN
     - make gh-linkcheck
     - make html
-    - ./check_doc_warnings.sh
+    - ../check_doc_warnings.sh
 
 test_nvs_on_host:
   stage: test
index 4107b9929e2c3a543645907164e597e29d61fd7c..87bf6b3974a7aec0ff7352fe0e12c28fb15a4bf4 100755 (executable)
@@ -2,8 +2,7 @@
 #
 # Check for Documentation warnings:
 # doxygen-warning-log.txt should be an empty file
-# sphinx-warning-log.txt should only contain (fuzzy) matches to sphinx-known-warnings.txt
-cd "$(dirname $0)"
+# sphinx-warning-log.txt should only contain (fuzzy) matches to ../sphinx-known-warnings.txt
 RESULT=0
 STARS='***************************************************'
 
@@ -22,19 +21,19 @@ sed -r 's:\x1B\[[0-9;]*[mK]::g' sphinx-warning-log.txt | \
     sed -E "s~${IDF_PATH}~\${IDF_PATH}~" | \
     sed -E "s/:[0-9]+:/:line:/" > sphinx-warning-log-sanitized.txt
 
-# diff sanitized warnings, ignoring lines which only appear in sphinx-known-warnings.txt
+# diff sanitized warnings, ignoring lines which only appear in ../sphinx-known-warnings.txt
 
 # format is to display only lines new or changed in second argument
 DIFF_FORMAT="--unchanged-line-format= --old-line-format= --new-line-format=%L"
 
-SPHINX_WARNINGS=$(diff $DIFF_FORMAT sphinx-known-warnings.txt sphinx-warning-log-sanitized.txt)
+SPHINX_WARNINGS=$(diff $DIFF_FORMAT ../sphinx-known-warnings.txt sphinx-warning-log-sanitized.txt)
 if ! [ -z "$SPHINX_WARNINGS" ]; then
     echo "$STARS"
     echo "Build failed due to new/different Sphinx warnings:"
     echo "$SPHINX_WARNINGS"
     echo "$STARS"
     RESULT=1
-    echo "(Check files sphinx-known-warnings.txt and sphinx-warning-log.txt for full details.)"
+    echo "(Check files ../sphinx-known-warnings.txt and sphinx-warning-log.txt for full details.)"
 fi
 
 exit $RESULT