mirror of
https://github.com/kou029w/megabit.git
synced 2025-01-31 06:08:03 +00:00
27 lines
646 B
YAML
27 lines
646 B
YAML
|
name: github-pages
|
||
|
on:
|
||
|
push:
|
||
|
branches: [master]
|
||
|
jobs:
|
||
|
main:
|
||
|
runs-on: ubuntu-latest
|
||
|
steps:
|
||
|
- uses: actions/checkout@v2
|
||
|
- uses: actions/setup-node@v2
|
||
|
with: { node-version: lts/*, cache: yarn }
|
||
|
- name: Git config
|
||
|
run: |
|
||
|
git config user.name bot
|
||
|
git config user.email bot@example
|
||
|
- name: Build
|
||
|
run: |
|
||
|
git subtree add --prefix docs origin gh-pages
|
||
|
yarn
|
||
|
yarn doc
|
||
|
- name: Publish
|
||
|
run: |
|
||
|
git add -f docs
|
||
|
if git commit -m update; then
|
||
|
git subtree push --prefix docs origin gh-pages
|
||
|
fi
|