Repository navigation
deps: update dependency ubuntu to v26 #150
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Publish docs to GitHub Pages | |
| on: | |
| workflow_dispatch: | |
| push: | |
| branches: | |
| - master | |
| paths: | |
| - docs/** | |
| - .github/workflows/docs-publish.yml | |
| pull_request: | |
| types: | |
| - opened | |
| - reopened | |
| - synchronize | |
| - closed | |
| paths: | |
| - docs/** | |
| - .github/workflows/docs-publish.yml | |
| permissions: | |
| contents: write | |
| pull-requests: write | |
| jobs: | |
| preview: | |
| name: Preview docs | |
| runs-on: ubuntu-26.04 | |
| if: (github.repository_owner == github.event.pull_request.head.repo.owner.login) && (github.event_name == 'pull_request') | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| with: | |
| persist-credentials: false | |
| - name: Set base URL | |
| run: | | |
| sed -i "s|baseUrl: '/marblerun/'|baseUrl: '/marblerun/pr-preview/pr-${{ github.event.number }}/'|" ./docs/docusaurus.config.js | |
| - name: Build | |
| working-directory: ./docs | |
| run: | | |
| npm i && npm run build | |
| - name: Deploy Preview | |
| uses: rossjrw/pr-preview-action@ffa7509e91a3ec8dfc2e5536c4d5c1acdf7a6de9 # v1.8.1 | |
| with: | |
| source-dir: ./docs/build | |
| publish: | |
| name: Publish docs to GitHub Pages | |
| runs-on: ubuntu-26.04 | |
| if: github.event_name == 'push' && github.ref_name == 'master' | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| with: | |
| persist-credentials: false | |
| - name: Build | |
| working-directory: ./docs | |
| run: | | |
| npm i && npm run build | |
| - name: Publish | |
| uses: JamesIves/github-pages-deploy-action@fa24774553152dd7873cd16ebd8d959b010c5445 # v4.9.0 | |
| with: | |
| folder: ./docs/build | |
| branch: gh-pages | |
| clean-exclude: pr-preview | |
| force: false |