File tree Expand file tree Collapse file tree 1 file changed +23
-0
lines changed Expand file tree Collapse file tree 1 file changed +23
-0
lines changed Original file line number Diff line number Diff line change 16
16
- name : Checkout
17
17
uses : actions/checkout@v4
18
18
19
+ - name : Cache node_modules
20
+ id : cache-node-modules
21
+ uses : actions/cache@v4
22
+ env :
23
+ cache-name : cache-node-modules
24
+ with :
25
+ path : node_modules
26
+ key : ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
27
+
28
+ - name : Setup node version and npm cache
29
+ uses : actions/setup-node@v4
30
+ with :
31
+ node-version-file : ' .nvmrc'
32
+ cache : ' npm'
33
+
34
+ - name : Install Node dependencies
35
+ if : steps.cache-node-modules.outputs.cache-hit != 'true'
36
+ run : npm ci --no-optional
37
+
38
+ - name : Build plugin
39
+ run : |
40
+ npm run build
41
+
19
42
- name : Generate ZIP file
20
43
uses : 10up/action-wordpress-plugin-build-zip@stable
21
44
env :
You can’t perform that action at this time.
0 commit comments