diff --git a/.github/workflows/ci-docs.yml b/.github/workflows/ci-docs.yml new file mode 100644 index 0000000000..f29393ff58 --- /dev/null +++ b/.github/workflows/ci-docs.yml @@ -0,0 +1,38 @@ +name: Documentation generation + +on: + push: + branches: + - master + +jobs: + lint: + name: Generate docs and push to github pages + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + + - name: Read .nvmrc + run: echo ::set-output name=NVMRC::$(cat .nvmrc) + id: nvm + + - name: Set up Node.js + uses: actions/setup-node@v2 + with: + node-version: '${{ steps.nvm.outputs.NVMRC }}' + + - name: Set up yarn + run: npm install --global yarn + + - name: Set up dependencies + run: yarn + + - name: Generate docs + run: yarn docs + + - name: Deploy Github Page + uses: peaceiris/actions-gh-pages@v3 + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + publish_dir: ./docs diff --git a/.github/workflows/ci-master.yml b/.github/workflows/ci-master.yml index e4a9b2bb84..e228a39250 100644 --- a/.github/workflows/ci-master.yml +++ b/.github/workflows/ci-master.yml @@ -36,9 +36,3 @@ jobs: - name: Build bundle run: yarn build - - - name: Deploy Github Page - uses: peaceiris/actions-gh-pages@v3 - with: - github_token: ${{ secrets.GITHUB_TOKEN }} - publish_dir: ./docs