48 lines (41 loc) · 1.45 KB
/
etl.yml
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
42
43
44
45
46
47
48
name: Extract, Transform & Load
on:
# Build on pushes branches that have a PR (including drafts)
pull_request:
# Build on commits pushed to branches without a PR if it's in the allowlist
push:
branches: [next]
jobs:
etl:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@755da8c3cf115ac066823e79a1e1788f8940201b # v3
- name: Cache node modules
id: cache-node-modules
uses: actions/cache@4723a57e26efda3a62cbde1812113b730952852d # v3
env:
cache-name: cache-node-modules
with:
path: '**/node_modules'
key: ${{ runner.os }}-modules-${{ env.cache-name }}-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-modules-${{ env.cache-name }}-
${{ runner.os }}-modules-
${{ runner.os }}-
- name: Install project dependencies
if: steps.cache-node-modules.outputs.cache-hit != 'true'
env:
# Keep the Cypress binary in ./node_modules/.cypress
CYPRESS_CACHE_FOLDER: './node_modules/.cypress'
CYPRESS_INSTALL_BINARY: '0'
PUPPETEER_SKIP_DOWNLOAD: 'true'
run: yarn install
- name: Build packages
run: yarn build
env:
NODE_OPTIONS: --max_old_space_size=8192
- name: Extract API docs
env:
EXTRACT_SANITY_API_TOKEN: ${{ secrets.EXTRACT_SANITY_API_TOKEN }}
run: yarn etl --quiet