build(actions): init auto build github actions
This commit is contained in:
32
.github/workflows/gh-pages.yaml
vendored
Normal file
32
.github/workflows/gh-pages.yaml
vendored
Normal file
@@ -0,0 +1,32 @@
|
||||
name: Build release and push to Github
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ main ]
|
||||
|
||||
jobs:
|
||||
build:
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
strategy:
|
||||
matrix:
|
||||
node-version: [20.x]
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- name: Use Node.js ${{ matrix.node-version }}
|
||||
uses: actions/setup-node@v3
|
||||
with:
|
||||
node-version: ${{ matrix.node-version }}
|
||||
- name: Install dependencies
|
||||
run: npm ci
|
||||
- name: Build all
|
||||
run: npm run build-all
|
||||
- name: Deploy
|
||||
uses: s0/git-publish-subdir-action@develop
|
||||
env:
|
||||
REPO: self
|
||||
BRANCH: gh-pages
|
||||
FOLDER: release
|
||||
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
|
||||
Reference in New Issue
Block a user