-
Notifications
You must be signed in to change notification settings - Fork 0
42 lines (39 loc) · 1.31 KB
/
docs.yaml
File metadata and controls
42 lines (39 loc) · 1.31 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
name: Check if Reference Docs need to be regenerated
on:
pull_request
jobs:
docs:
runs-on: ubuntu-latest
name: Build
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup node
uses: actions/setup-node@v2-beta
with:
node-version: '14'
- name: node_modules cache
id: node_modules_cache
uses: actions/cache@v2
with:
path: ./node_modules
key: ${{ runner.os }}-14-node_modules-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-14-node_modules-
- name: Yarn offline cache
if: steps.node_modules_cache.outputs.cache-hit != 'true'
uses: actions/cache@v2
with:
path: ~/.npm-packages-offline-cache
key: yarn-offline-${{ hashFiles('**/yarn.lock') }}
restore-keys: yarn-offline
- name: Install deps
if: steps.node_modules_cache.outputs.cache-hit != 'true'
run: |
yarn config set yarn-offline-mirror ~/.npm-packages-offline-cache
yarn config set yarn-offline-mirror-pruning true
yarn install --frozen-lockfile --prefer-offline
- name: Generate reference docs
run: yarn docs
- name: Check for diff
run: git diff --exit-code -- 'docs/reference***.md'