InfoLens / .github /workflows /github-pages.yml
dqy08's picture
插件累积更新:动态跟踪、收藏到手机、本机 Qwen 与自定义 API,其它改进重构等。
e3894fa
Raw History Blame Contribute Delete
1.06 kB
name: Deploy GitHub Pages
on:
push:
branches: [main]
workflow_dispatch:
permissions:
contents: read
pages: write
id-token: write
concurrency:
group: pages
cancel-in-progress: true
jobs:
deploy:
# 只在公开仓运行;私有仓 main 是开发主线,不能同步出去。
if: github.repository == 'dqy08/InfoLens'
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- uses: actions/checkout@v4
with:
lfs: true
- uses: actions/setup-node@v4
with:
node-version: '20'
cache: npm
cache-dependency-path: client/src/package-lock.json
- name: Build static site
run: cd client/src && npm ci && npm run build:github-pages
- name: Disable Jekyll
run: touch client/dist-github_pages/.nojekyll
- uses: actions/upload-pages-artifact@v3
with:
path: client/dist-github_pages
- uses: actions/deploy-pages@v4
id: deployment