diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3a190ef27..d8a1fdffd 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -8,8 +8,6 @@ jobs: build: name: ${{ matrix.config.name }} runs-on: ${{ matrix.config.os }} - env: - HDOC_PROJECT_API_KEY: ${{ secrets.HDOC_PROJECT_API_KEY }} strategy: fail-fast: false matrix: @@ -166,13 +164,6 @@ jobs: message(FATAL_ERROR "Running tests failed!") endif() - - name: Documentation - if: ${{ startsWith(matrix.config.cxx, 'g++') && env.HDOC_PROJECT_API_KEY != '' }} - uses: hdoc/hdoc-github-action@v2 - with: - compile-commands-path: out/compile_commands.json - hdoc-api-key: ${{ env.HDOC_PROJECT_API_KEY }} - - name: Install Strip run: cmake --install out --prefix instdir --strip diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml new file mode 100644 index 000000000..2fada4d6b --- /dev/null +++ b/.github/workflows/docs.yml @@ -0,0 +1,25 @@ +name: docs + +on: + push: + branches: [main] + +jobs: + docs: + name: Generate documentation + if: github.repository == 'chromium/subspace' + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v1 + + - name: Configure + run: | + sudo apt install build-essential cmake ninja-build + cmake -G Ninja -B out -D CMAKE_EXPORT_COMPILE_COMMANDS=1 + + - name: Documentation + uses: hdoc/hdoc-github-action@v2 + with: + compile-commands-path: out/compile_commands.json + hdoc-api-key: ${{ secrets.HDOC_PROJECT_API_KEY }}