1
1
mirror of https://github.com/wez/wezterm.git synced 2024-09-11 22:37:11 +03:00

ci: docs: deploy directly, rather than via gh_pages branch

This commit is contained in:
Wez Furlong 2023-02-25 17:49:57 -07:00
parent c5247d21fa
commit 494fab09ba
No known key found for this signature in database
GPG Key ID: 7A7F66A31EC9B387

View File

@ -14,8 +14,21 @@ on:
schedule: schedule:
- cron: "50 * * * *" - cron: "50 * * * *"
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write
concurrency:
group: "pages"
cancel-in-progress: true
jobs: jobs:
publish: build:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Checkout - name: Checkout
@ -56,13 +69,18 @@ jobs:
run: | run: |
source $HOME/.cargo/env source $HOME/.cargo/env
./ci/build-docs.sh ./ci/build-docs.sh
- name: Deploy - name: Upload artifact
if: success() uses: actions/upload-pages-artifact@v1
uses: crazy-max/ghaction-github-pages@v3
with: with:
target_branch: gh-pages path: gh_pages/html
build_dir: gh_pages/html
keep_history: true deploy:
allow_empty_commit: false environment:
env: name: github-pages
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
needs: build
steps:
- name: Deploy
id: deployment
uses: actions/deploy-pages@v1