File tree 1 file changed +33
-6
lines changed
1 file changed +33
-6
lines changed Original file line number Diff line number Diff line change 7
7
- main
8
8
9
9
jobs :
10
- build :
11
- name : Build
10
+ release :
11
+ name : Release
12
12
runs-on : ubuntu-latest
13
13
permissions :
14
14
contents : write
15
15
16
16
steps :
17
- - uses : actions/checkout@v4
17
+ - name : Checkout tools repo
18
+ uses : actions/checkout@v4
19
+ with :
20
+ repository : Consensys/docs-gha
21
+ path : .docs-gha
22
+
23
+ - name : Get additional Github env vars # vars from Github env, can not be modified by users
24
+ uses : FranzDiebold/github-env-vars-action@v2
25
+
26
+ - name : Read .nvmrc
27
+ shell : bash
28
+ run : echo "NODE_VERSION=$(cat .nvmrc)" >> $GITHUB_OUTPUT
29
+ id : nvm
30
+
31
+ - name : Use Node.js ${{ steps.nvm.outputs.NODE_VERSION }}
32
+ uses : actions/setup-node@v4
33
+ with :
34
+ node-version : ${{ steps.nvm.outputs.NODE_VERSION }}
35
+ registry-url : https://registry.npmjs.org/
36
+
37
+ - name : npm build
38
+ shell : bash
39
+ run : |
40
+ npm ci --only=production
41
+ npm run build
18
42
19
- - name : Build
20
- uses : Consensys/docs-gha/release@main
43
+ - name : Deploy Preview
44
+ uses : JamesIves/github-pages-deploy-action@v4
21
45
with :
22
- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
46
+ branch : gh-pages
47
+ folder : build # The folder the action should deploy.
48
+ clean : true
49
+ single-commit : true
You can’t perform that action at this time.
0 commit comments