File tree Expand file tree Collapse file tree 3 files changed +11
-7
lines changed
Expand file tree Collapse file tree 3 files changed +11
-7
lines changed Original file line number Diff line number Diff line change 7575 cp -rf executorch_android/build/intermediates/java_doc_dir/release/javaDocReleaseGeneration "${RUNNER_DOCS_DIR}/javadoc"
7676 cd ../..
7777
78- # Note: noindex meta tag is automatically added by conf.py for non-stable releases (main, dev versions)
78+ # If it's main branch, add noindex tag to all .html files to exclude from Google Search indexing.
79+ echo "GitHub Ref: ${GITHUB_REF}"
80+ if [[ "${{ github.ref }}" == 'refs/heads/main' ]]; then
81+ find docs/_build/html/ -name "*.html" -print0 | xargs -0 sed -i '/<head>/a \ \ <meta name="robots" content="noindex">';
82+ fi
7983
8084 cp -rf docs/_build/html/* "${RUNNER_DOCS_DIR}"
8185
Original file line number Diff line number Diff line change @@ -74,6 +74,12 @@ ignore_missing_imports = True
7474[mypy-pytorch_sphinx_theme]
7575ignore_missing_imports = True
7676
77+ [mypy-pytorch_sphinx_theme2]
78+ ignore_missing_imports = True
79+
80+ [mypy-executorch.version]
81+ ignore_missing_imports = True
82+
7783[mypy-ruamel]
7884ignore_missing_imports = True
7985
Original file line number Diff line number Diff line change 255255 "display_version" : True ,
256256}
257257
258- # Control the noindex meta tag based on version
259- # Only add noindex for main branch (not stable releases)
260- if not RELEASE :
261- html_meta = {
262- "robots" : "noindex" ,
263- }
264258
265259# Add any paths that contain custom static files (such as style sheets) here,
266260# relative to this directory. They are copied after the builtin static files,
You can’t perform that action at this time.
0 commit comments