mirror of
https://github.com/motajs/template.git
synced 2026-11-01 06:04:30 +08:00
init: 2.B
This commit is contained in:
commit
6bf32174d8
610 files changed
+151444
No files matched your search
@@ -0,0 +1,38 @@
|
||||
# Simple workflow for deploying static content to GitHub Pages
|
||||
name: Deploy static content to Pages
|
||||
|
||||
on:
|
||||
# Runs on pushes targeting the default branch
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
|
||||
# Allow one concurrent deployment
|
||||
concurrency:
|
||||
group: 'pages'
|
||||
cancel-in-progress: true
|
||||
|
||||
jobs:
|
||||
# Single deploy job since we're just deploying
|
||||
deploy:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
persist-credentials: false
|
||||
|
||||
# 执行依赖安装
|
||||
- name: 安装依赖
|
||||
run: |
|
||||
npm i -g pnpm@7.27.0
|
||||
pnpm i
|
||||
pnpm build
|
||||
|
||||
# 执行部署
|
||||
- name: 部署
|
||||
uses: JamesIves/github-pages-deploy-action@releases/v3 # 这个action会根据配置自动推送代码到指定分支
|
||||
with:
|
||||
ACCESS_TOKEN: ${{ secrets.ACCESS_TOKEN }} # 指定密钥
|
||||
BRANCH: gh-pages ##指定推送到的远程分支
|
||||
FOLDER: dist # 指定构建之后要推送哪个目录的代码
|
||||
Reference in new issue
Block a user