From 4306d12f83d8b65118e5370db4cf0faf549b24a8 Mon Sep 17 00:00:00 2001 From: Ju4tCode <42488585+yanyongyu@users.noreply.github.com> Date: Sun, 13 Sep 2020 22:32:55 +0800 Subject: [PATCH] :construction_worker: add api docs ci --- .github/workflows/api_docs.yml | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 .github/workflows/api_docs.yml diff --git a/.github/workflows/api_docs.yml b/.github/workflows/api_docs.yml new file mode 100644 index 00000000..01c1c4a8 --- /dev/null +++ b/.github/workflows/api_docs.yml @@ -0,0 +1,31 @@ +name: Build API Doc + +on: + pull_request: + types: [ opened, synchronize, reopened ] + branches: [ master, dev ] + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + with: + ref: ${{ github.event.pull_request.head.sha }} + + - name: Install Dependences + run: pip3 install . + + - name: Build Doc + run: sphinx-build -M markdown ./docs_build ./build + + - name: Copy Files + run: cp ./build/markdown/*.md ./docs/api/ + + - run: | + git config user.name nonebot + git config user.email nonebot@nonebot.dev + git add . + git commit -m ":memo: update api docs" + git push