5
5
6
6
jobs :
7
7
publish :
8
- name : publish
8
+ name : Publish crates
9
9
runs-on : ubuntu-latest
10
10
timeout-minutes : 60
11
+ env :
12
+ RUSTFLAGS : -D warnings
11
13
steps :
12
14
- name : Checkout repository
13
15
uses : actions/checkout@v3
@@ -36,21 +38,28 @@ jobs:
36
38
--from-git \
37
39
--yes \
38
40
--no-git-commit \
39
- --no-git-push \
40
- --no-individual-tags \
41
41
skip
42
42
43
43
doc-publish :
44
- # needs: publish
44
+ name : Publish documentation
45
+ needs : publish
45
46
runs-on : ubuntu-latest
46
47
timeout-minutes : 60
47
48
steps :
48
- - uses : actions/checkout@v3
49
+ - uses : actions/checkout@v4
50
+ - name : Install Rust toolchain
51
+ uses : actions-rs/toolchain@v1
52
+ with :
53
+ toolchain : stable
54
+ profile : minimal
55
+ override : true
49
56
- name : Install wasm-pack
50
- run : curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh
57
+ uses :
baptiste0928/[email protected]
58
+ with :
59
+ crate : wasm-pack
51
60
- uses : actions/setup-node@v3
52
61
with :
53
- node-version : " 16 "
62
+ node-version : " 20 "
54
63
- run : npm ci
55
64
- name : Cache npm build
56
65
uses : actions/cache@v3
62
71
~/.cargo/git
63
72
~/.cargo/registry
64
73
key : ${{ runner.os }}-npm-build-target-${{ hashFiles('**/package-lock.json') }}
74
+ - run : wasm-pack build ./boa_wasm
65
75
- run : npm run build:prod
66
76
- name : Deploy
67
77
uses : peaceiris/actions-gh-pages@v3
72
82
73
83
release-binaries :
74
84
name : Publish binaries
85
+ needs : publish
75
86
strategy :
76
87
fail-fast : false
77
88
matrix :
@@ -82,25 +93,34 @@ jobs:
82
93
rust : stable
83
94
target : x86_64-unknown-linux-gnu
84
95
asset_name : boa-linux-amd64
96
+ binary_name : boa
85
97
- build : macos
86
98
os : macos-latest
87
99
rust : stable
88
100
target : x86_64-apple-darwin
89
101
asset_name : boa-macos-amd64
102
+ binary_name : boa
90
103
- build : win-msvc
91
104
os : windows-2019
92
105
rust : stable
93
106
target : x86_64-pc-windows-msvc
94
107
asset_name : boa-windows-amd64
108
+ binary_name : boa.exe
95
109
runs-on : ${{ matrix.os }}
96
110
steps :
97
- - uses : actions/checkout@v3
98
- - name : Build
99
- run : cargo build --target ${{ matrix.target }} --verbose --release --locked --bin boa
100
- - name : Upload binaries to release
101
- uses : svenstaro/upload-release-action@v2
102
- with :
103
- repo_token : ${{ secrets.GITHUB_TOKEN }}
104
- file : target/release/${{ matrix.target }}
105
- asset_name : ${{ matrix.asset_name }}
106
- tag : ${{ github.ref }}
111
+ - uses : actions/checkout@v4
112
+ - name : Install Rust toolchain
113
+ uses : actions-rs/toolchain@v1
114
+ with :
115
+ toolchain : stable
116
+ profile : minimal
117
+ override : true
118
+ - name : Build
119
+ run : cargo build --target ${{ matrix.target }} --verbose --release --locked --bin boa
120
+ - name : Upload binaries to release
121
+ uses : svenstaro/upload-release-action@v2
122
+ with :
123
+ repo_token : ${{ secrets.GITHUB_TOKEN }}
124
+ file : target/${{ matrix.target }}/release/${{ matrix.binary_name }}
125
+ asset_name : ${{ matrix.asset_name }}
126
+ tag : ${{ github.ref }}
0 commit comments