File tree Expand file tree Collapse file tree 1 file changed +41
-0
lines changed Expand file tree Collapse file tree 1 file changed +41
-0
lines changed Original file line number Diff line number Diff line change @@ -107,6 +107,10 @@ jobs:
107
107
name : run PHP build step
108
108
command : ./.ci/build/php
109
109
110
+ - run :
111
+ name : install theme composer dependencies
112
+ command : cd web/wp-content/themes/sage && composer install
113
+
110
114
- save_cache :
111
115
key : vendor-{{ checksum "composer.lock" }}
112
116
paths :
@@ -118,6 +122,41 @@ jobs:
118
122
- web
119
123
- vendor
120
124
125
+ build_yarn :
126
+ << : *defaults
127
+ docker :
128
+ - image : circleci/node:10.16.2
129
+
130
+ steps :
131
+ - checkout
132
+
133
+ - restore_cache :
134
+ keys :
135
+ - yarn-packages-{{ checksum "web/wp-content/themes/sage/yarn.lock" }}
136
+ - yarn-packages- # used if checksum fails
137
+
138
+ - run :
139
+ name : install theme yarn dependencies
140
+ command : cd web/wp-content/themes/sage && yarn install
141
+
142
+ - run :
143
+ name : build theme assets
144
+ # If non-hashed versions of site assets are needed for 3rd parties, also run `yarn build:nohash`
145
+ command : cd web/wp-content/themes/sage && yarn build
146
+
147
+ - save_cache :
148
+ name : cache Yarn files
149
+ key : yarn-packages-{{ checksum "web/wp-content/themes/sage/yarn.lock" }}
150
+ paths :
151
+ - $HOME/.cache/yarn
152
+
153
+ - persist_to_workspace :
154
+ # Must be relative path from working_directory
155
+ root : .
156
+ # Must be relative path from root
157
+ paths :
158
+ - web/wp-content/themes/sage/dist
159
+
121
160
deploy_to_pantheon :
122
161
<< : *defaults
123
162
steps :
@@ -231,10 +270,12 @@ workflows:
231
270
jobs :
232
271
- configure_env_vars
233
272
# - static_tests
273
+ - build_yarn
234
274
- build_php
235
275
- deploy_to_pantheon :
236
276
requires :
237
277
# - static_tests
278
+ - build_yarn
238
279
- build_php
239
280
# - visual_regression_test:
240
281
# requires:
You can’t perform that action at this time.
0 commit comments