Skip to content

docs: update README #31

docs: update README

docs: update README #31

Workflow file for this run

name: deploy gh-page
on:
push:
branches: [main]
jobs:
build:
name: build and deploy gh-page
env:
COMMIT_SECRET: ${{secrets.COMMIT_SECRET}}
USER_NAME: songlh
USER_EMAIL: [email protected]
PUBLISH_DIR: ./dist
GITHUB_REPOSITORY: paint-board
runs-on: ubuntu-latest
steps:
- name: checkout repository main branch
uses: actions/checkout@main
- name: with node.js
uses: actions/setup-node@v1
with:
node-version: 18.x
- name: npm install
run: |
npm install -g pnpm
pnpm install
- name: npm run build
run: |
pnpm build
- name: commit files
run: |
cd $PUBLISH_DIR
git init
git config --local user.name $USER_NAME
git config --local user.email $USER_EMAIL
git status
git remote add origin https://[email protected]/$GITHUB_REPOSITORY.git
git checkout -b gh-pages
git add --all
git commit -m "deploy to github pages"
git push origin gh-pages -f
echo deploy gh-pages complete