mirror of
https://github.com/HIllya51/LunaTranslator.git
synced 2025-11-29 09:30:21 +08:00
49 lines
1 KiB
YAML
49 lines
1 KiB
YAML
name: _
|
|
|
|
on:
|
|
push:
|
|
paths: [ 'docs/**', '.github/workflows/docbuild.yml']
|
|
pull_request:
|
|
paths: [ 'docs/**', '.github/workflows/docbuild.yml']
|
|
|
|
permissions:
|
|
contents: read
|
|
pages: write
|
|
id-token: write
|
|
|
|
concurrency:
|
|
group: "pages"
|
|
cancel-in-progress: false
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@master
|
|
with:
|
|
fetch-depth: '0'
|
|
ref: main
|
|
- run: |
|
|
cd docs
|
|
- uses: actions/setup-node@master
|
|
with:
|
|
node-version: 22
|
|
- uses: actions/configure-pages@v4
|
|
- run: |
|
|
cd docs
|
|
npm install
|
|
npm run docs:build
|
|
cp index.html .vitepress/dist
|
|
cd ..
|
|
- uses: actions/upload-pages-artifact@v3
|
|
with:
|
|
path: docs/.vitepress/dist
|
|
deploy:
|
|
environment:
|
|
name: github-pages
|
|
url: ${{ steps.deployment.outputs.page_url }}
|
|
needs: build
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- id: deployment
|
|
uses: actions/deploy-pages@v4
|