Skip to content

Merge pull request #54 from wszgrcy/alpha #37

Merge pull request #54 from wszgrcy/alpha

Merge pull request #54 from wszgrcy/alpha #37

Workflow file for this run

name: deploy
on:
push:
branches:
- master
env:
REPOSITORY_PATH: https://${{secrets.ACCESS_TOKEN}}@github.com/
# GITHUB_TOKEN: ${{secrets.ACCESS_TOKEN}}
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: init
run: |
git config --global user.name "${GITHUB_ACTOR}"
git config --global user.email "${GITHUB_ACTOR}@gmail.com"
- name: pull-code
uses: actions/checkout@v2
- name: install-node
uses: actions/setup-node@v2
with:
node-version: 16.x
cache: "npm"
- name: install-dependencies
run: |
npm ci --legacy-peer-deps
- name: hook-code
run: |
npm run sync
- name: build-docs
continue-on-error: true
run: |
npm run deploy
cp -rp docs/ ../dist
git branch gh-pages
git checkout gh-pages
rm -rf *
cp -rp ../dist/* .
cp ./index.html 404.html
env:
INPUT_TOKEN: ''
- name: tag
run: |
git status
git add -A
HUSKY=0 git commit -m 'build: 页面构建'
HUSKY=0 git push --force "${REPOSITORY_PATH}${GITHUB_REPOSITORY}.git" gh-pages
# git pull