@@ -17,14 +17,10 @@ jobs:
17
17
matrix :
18
18
node : [14, 16]
19
19
os : [ubuntu-latest, macos-latest, windows-latest]
20
- include :
21
- - os : ubuntu-latest
22
- node : 16
23
- docsTarget : true
24
20
runs-on : ${{ matrix.os }}
25
21
steps :
26
22
- name : Print build information
27
- run : ' echo head_ref: ${{ github.head_ref }}, ref: ${{ github.ref }}, os: ${{ matrix.os }}, node: ${{ matrix.node }}, docsTarget: ${{ toJson(matrix.docsTarget) }} '
23
+ run : ' echo head_ref: ${{ github.head_ref }}, ref: ${{ github.ref }}, os: ${{ matrix.os }}, node: ${{ matrix.node }}'
28
24
- uses : actions/checkout@v2
29
25
with :
30
26
submodules : recursive
@@ -71,22 +67,39 @@ jobs:
71
67
~/.npm/_logs/
72
68
C:\npm\cache\_logs\
73
69
70
+ build-docs :
71
+ runs-on : ubuntu-latest
72
+ steps :
73
+ - uses : actions/checkout@v2
74
+ with :
75
+ submodules : recursive
76
+ - uses : actions-rs/toolchain@v1
77
+ with :
78
+ toolchain : stable
79
+ - uses : actions/setup-node@v1
80
+ with :
81
+ node-version : 16
82
+ # Don't build during install phase since we're going to explicitly build
83
+ - run : npm ci --ignore-scripts
84
+ - run : npm run build
85
+ env :
86
+ BUILD_CORE_RELEASE : true
87
+
74
88
# Do docs stuff (only on one host)
75
89
- name : Build docs
76
- if : ${{ matrix.docsTarget }}
77
90
run : npm run docs
78
91
env :
79
92
ALGOLIA_API_KEY : ${{ secrets.ALGOLIA_API_KEY }}
80
- - name : Deploy prod docs
81
- if : ${{ github.ref == 'refs/heads/main' && matrix.docsTarget }}
93
+ - name : Deploy prod docs # TODO: only deploy prod docs when we publish a new version
94
+ if : ${{ github.ref == 'refs/heads/main' }}
82
95
uses : netlify/actions/cli@master
83
96
with :
84
97
args : deploy --dir=packages/docs/build --prod
85
98
env :
86
99
NETLIFY_SITE_ID : ${{ secrets.NETLIFY_SITE_ID }}
87
100
NETLIFY_AUTH_TOKEN : ${{ secrets.NETLIFY_AUTH_TOKEN }}
88
101
- name : Deploy draft docs
89
- if : ${{ github.ref != 'refs/heads/main' && matrix.docsTarget }}
102
+ if : ${{ github.ref != 'refs/heads/main' }}
90
103
uses : netlify/actions/cli@master
91
104
with :
92
105
args : deploy --dir=packages/docs/build
0 commit comments