diff --git a/.github/workflows/CI.yaml b/.github/workflows/CI.yaml index 32ae553..12f4064 100644 --- a/.github/workflows/CI.yaml +++ b/.github/workflows/CI.yaml @@ -9,6 +9,7 @@ on: push: branches: - main + - ci_test tags: - '*' pull_request: @@ -28,8 +29,8 @@ jobs: target: x86_64 - runner: ubuntu-latest target: x86 -# - runner: ubuntu-latest -# target: aarch64 + # - runner: ubuntu-latest + # target: aarch64 - runner: ubuntu-latest target: armv7 - runner: ubuntu-latest @@ -92,8 +93,8 @@ jobs: platform: - runner: windows-latest target: x64 -# - runner: windows-latest -# target: x86 + # - runner: windows-latest + # target: x86 steps: - uses: actions/checkout@v4 - uses: actions/setup-python@v5 @@ -157,7 +158,7 @@ jobs: name: Release runs-on: ubuntu-latest if: "startsWith(github.ref, 'refs/tags/')" - needs: [linux, musllinux, windows, macos, sdist] + needs: [ linux, musllinux, windows, macos, sdist ] steps: - uses: actions/download-artifact@v4 - name: Publish to PyPI @@ -165,3 +166,59 @@ jobs: with: command: upload args: --non-interactive --skip-existing wheels-*/* + + build-docs: + needs: linux + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - uses: actions/setup-python@v4 + with: + python-version: '3.10' + - uses: actions/download-artifact@v4 + with: + name: wheels-linux-x86_64 + path: wheels/ + - name: "Install packages" + run: | + pip install -U sphinx sphinx_rtd_theme + pip install wheels/*.whl + - name: "Build docs" + working-directory: docs + run: sphinx-build -b html source build + - name: Fix permissions + run: | + chmod -c -R +rX "docs/build/" | while read line; do + echo "::warning title=Invalid file permissions automatically fixed::$line" + done + - name: Upload Pages artifact + uses: actions/upload-pages-artifact@v3 + with: + path: docs/build + + # Deploy job + deploy-docs: + # Add a dependency to the build job + needs: build-docs + + # Grant GITHUB_TOKEN the permissions required to make a Pages deployment + permissions: + contents: read + pages: write # to deploy to Pages + id-token: write # to verify the deployment originates from an appropriate source + + # Deploy to the github-pages environment + environment: + name: github-pages + url: ${{ steps.deployment.outputs.page_url }} + + # Specify runner + deployment step + runs-on: ubuntu-latest + steps: + - name: Deploy to GitHub Pages + id: deployment + uses: actions/deploy-pages@v4 # or specific "vX.X.X" version tag for this action + + + + diff --git a/.github/workflows/docs.yaml b/.github/workflows/docs.yaml deleted file mode 100644 index f82be04..0000000 --- a/.github/workflows/docs.yaml +++ /dev/null @@ -1,67 +0,0 @@ -on: - push: - branches: - - main -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true -jobs: - docs: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 - with: - python-version: '3.10' - - name: Download artifact - id: download-artifact - uses: dawidd6/action-download-artifact@v5 - with: - workflow: "CI.yaml" - branch: ${{ github.ref }} - name: wheels-linux-x86_64 - path: wheels/ - - name: "Install packages" - run: | - pip install -U sphinx sphinx_rtd_theme - pip install wheels/*.whl - - name: "Build docs" - working-directory: docs - run: sphinx-build -b html source build - - name: Fix permissions - run: | - chmod -c -R +rX "docs/build/" | while read line; do - echo "::warning title=Invalid file permissions automatically fixed::$line" - done - - name: Upload Pages artifact - uses: actions/upload-pages-artifact@v3 - with: - path: docs/build - - # Deploy job - deploy: - # Add a dependency to the build job - needs: docs - - # Grant GITHUB_TOKEN the permissions required to make a Pages deployment - permissions: - contents: read - pages: write # to deploy to Pages - id-token: write # to verify the deployment originates from an appropriate source - - # Deploy to the github-pages environment - environment: - name: github-pages - url: ${{ steps.deployment.outputs.page_url }} - - # Specify runner + deployment step - runs-on: ubuntu-latest - steps: - - name: Deploy to GitHub Pages - id: deployment - uses: actions/deploy-pages@v4 # or specific "vX.X.X" version tag for this action - - - - - \ No newline at end of file