From 5d2dfa83c7091d6685c133c171e9b06e145490e9 Mon Sep 17 00:00:00 2001 From: Gareth Jones Date: Sun, 12 Jul 2020 15:06:28 +1200 Subject: [PATCH] ci: check that docs don't need to be regenerated --- .github/workflows/lint.yml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index a23bdef05..232a241c3 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -13,6 +13,24 @@ jobs: configFile: './package.json' env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + docs: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + - uses: actions/setup-node@v2.1.0 + with: + node-version: 12.x + - name: install + run: yarn + - name: regenerate docs + run: yarn tools:regenerate-docs + - name: report regenerated docs + run: | + git diff --name-only \ + | xargs -I '{}' bash -c \ + 'echo "::error file={}::This needs to be regenerated by running \`tools:regenerate-docs\`" && false' danger: runs-on: ubuntu-latest steps: