Skip to content

#4003: Add script to help with finding issues that we need approval for #1764

#4003: Add script to help with finding issues that we need approval for

#4003: Add script to help with finding issues that we need approval for #1764

name: Docs - Build latest docs and deploy to GitHub pages on main
on:
push:
branches: ["main"]
workflow_dispatch:
permissions:
actions: read
contents: read
pages: write
id-token: write
concurrency:
# Note that people may spam the post-commit pipeline on their branch, and
# we have this docs pipeline in the post-commit pipeline, then people
# would have to wait until the previous one fully completes. That may be
# ok because each post-commit pipeline definitely takes more than 30 min
group: "pages-${{ github.ref }}"
cancel-in-progress: false
jobs:
build-deploy-docs:
strategy:
# Do not fail-fast because we need to ensure all tests go to completion
# so we try not to get hanging machines
fail-fast: false
matrix:
arch: [grayskull]
env:
TT_METAL_ENV: ${{ vars.TT_METAL_ENV }}
DOCS_VERSION: latest
ARCH_NAME: ${{ matrix.arch }}
environment: dev
runs-on: ubuntu-20.04
steps:
- uses: tenstorrent-metal/metal-workflows/.github/actions/checkout-with-submodule-lfs@main
- uses: ./.github/actions/install-metal-deps
with:
os: ubuntu-20.04
- uses: ./.github/actions/install-metal-dev-deps
with:
os: ubuntu-20.04
- name: Build tt-metal
run: |
export TT_METAL_HOME=$(pwd)
make build
- name: Activate docs environment and build docs
run: |
export PYTHONPATH=$(pwd)
source build/python_env/bin/activate
cd docs/
make html
- name: Build additional ttnn sweeps docs
env:
GITHUB_TOKEN: ${{ github.token }}
run: |
export PYTHONPATH=$(pwd)
source build/python_env/bin/activate
cd docs/
make ttnn_sweeps/check_directory
make ttnn_sweeps
- name: Prepare artifact - move output
run: |
mkdir gh_pages
mv docs/build/html gh_pages/$DOCS_VERSION
- name: Prepare artifact - create .nojekyll
run: |
touch gh_pages/.nojekyll
- name: Prepare artifact - create root index
run: |
touch gh_pages/index.html
- name: Upload artifact
uses: actions/upload-pages-artifact@v1
with:
path: "gh_pages"
- name: Deploy to GitHub Pages
if: ${{ github.ref == 'refs/heads/main' }}
id: deployment
uses: actions/deploy-pages@v2