docs: fix Quilt HTTP API name and sidebar (#2938) #1
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: Build docs and publish to GitHub Pages and Walrus | |
| on: | |
| push: | |
| branches: | |
| - "main" | |
| paths: | |
| - "docs/**" | |
| - ".github/workflows/publish-docs.yaml" | |
| workflow_dispatch: | |
| inputs: | |
| publish-pages: | |
| description: "Publish to GitHub Pages" | |
| type: boolean | |
| required: true | |
| default: false | |
| update-walrus-site: | |
| description: "Update the Walrus Site" | |
| type: boolean | |
| required: true | |
| default: false | |
| schedule: | |
| # Update Walrus Site every first day of the month at 03:14 UTC. | |
| - cron: "14 3 1 * *" | |
| concurrency: ci-${{ github.ref }} | |
| permissions: | |
| contents: read | |
| jobs: | |
| publish-github-pages: | |
| name: Publish to GitHub Pages | |
| runs-on: ubuntu-latest | |
| if: ${{ github.event_name == 'push' || inputs.publish-pages == true }} | |
| permissions: | |
| contents: write | |
| steps: | |
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # pin@v6.0.2 | |
| - name: Install pnpm | |
| uses: pnpm/action-setup@41ff72655975bd51cab0327fa583b6e92b6d3061 # pin@v4.2.0 | |
| with: | |
| version: 9 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # pin@v6.2.0 | |
| with: | |
| node-version: '20' | |
| cache: 'pnpm' | |
| cache-dependency-path: docs/site/pnpm-lock.yaml | |
| - name: Install dependencies | |
| run: cd docs/site && pnpm install --frozen-lockfile | |
| - name: Build site | |
| run: cd docs/site && pnpm run build | |
| - name: Update GitHub Pages | |
| uses: JamesIves/github-pages-deploy-action@d92aa235d04922e8f08b40ce78cc5442fcfbfa2f # pin@v4.8.0 | |
| with: | |
| folder: docs/site/build | |
| clean-exclude: pr-preview/ | |
| force: false | |
| # We store the data for the Sui wallet and the site object in GitHub variables | |
| # (https://github.com/MystenLabs/walrus/settings/variables/actions) and secrets | |
| # (https://github.com/MystenLabs/walrus/settings/secrets/actions). | |
| publish-walrus: | |
| name: Update Walrus Site | |
| runs-on: ubuntu-ghcloud | |
| if: ${{ github.event_name == 'push' || github.event_name == 'schedule' || inputs.update-walrus-site == true }} | |
| concurrency: | |
| group: sui-wallet-operations | |
| cancel-in-progress: false | |
| steps: | |
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # pin@v6.0.2 | |
| with: | |
| persist-credentials: false | |
| - name: Install pnpm | |
| uses: pnpm/action-setup@41ff72655975bd51cab0327fa583b6e92b6d3061 # pin@v4.2.0 | |
| with: | |
| version: 9 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # pin@v6.2.0 | |
| with: | |
| node-version: '20' | |
| cache: 'pnpm' | |
| cache-dependency-path: docs/site/pnpm-lock.yaml | |
| - name: Install dependencies | |
| run: cd docs/site && pnpm install --frozen-lockfile | |
| - name: Build site | |
| run: cd docs/site && pnpm run build | |
| - name: Deploy to Walrus | |
| uses: MystenLabs/walrus-sites-github-actions/deploy@8eb025e06e2aecea29cf16059be62faa3d4a64a5 # v2 | |
| with: | |
| SUI_ADDRESS: "${{ vars.SUI_ADDRESS }}" | |
| SUI_KEYSTORE: "${{ secrets.SUI_KEYSTORE }}" | |
| WALRUS_CONFIG: "${{ vars.WALRUS_CONFIG }}" | |
| SUI_NETWORK: mainnet | |
| DIST: docs/site/build | |
| WS_RESOURCES: docs/site/ws-resources.json | |
| EPOCHS: "10" | |
| GAS_BUDGET: "1000000000" | |
| SITE_BUILDER_VERSION: v2 |