docs: GitHub Actions deploy Workflow (#1644)

pull/1930/head
Luciano Felix 2 years ago committed by GitHub
parent ea4556febc
commit 4a19dde97b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -73,15 +73,17 @@ Don't enable options like _Auto Minify_ for HTML code. It will remove comments f
```yaml
name: Deploy
on:
workflow_dispatch: {}
push:
branches:
- main
jobs:
deploy:
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- uses: actions/checkout@v3
with:
@ -91,16 +93,15 @@ Don't enable options like _Auto Minify_ for HTML code. It will remove comments f
node-version: 16
cache: yarn
- run: yarn install --frozen-lockfile
- name: Build
run: yarn docs:build
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
- uses: actions/configure-pages@v2
- uses: actions/upload-pages-artifact@v1
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: docs/.vitepress/dist
# cname: example.com # if wanna deploy to custom domain
path: docs/.vitepress/dist
- name: Deploy
id: deployment
uses: actions/deploy-pages@v1
```
::: tip

Loading…
Cancel
Save