Commit 7b229bb
committed
support combining SDKs with multiple WIT worlds
This adds two new features:
- Multiple `--world` options are accepted, in which case the worlds will be
merged into a single world for building, testing, or bindings generation.
- In addition to any worlds and/or WIT paths specified explicitly via CLI
options, `componentize-go` will use `go list` to scan the current module and
its dependencies, looking for files named `componentize-go.toml` in their
source trees. For each such file found, any worlds and/or WIT paths
referenced therein will be added to the respective lists. This behavior can
be disabled using the `--ignore-toml-files` option if desired.
In combination, these options make it easier to use multiple SDKs or other
libraries which contain `wit-bindgen-go`-generated code.
Note that I've also removed the `wat` dependency because `go build` always
generates a binary Wasm file, so no need to check for or parse WAT.
Fixes #281 parent f365a7a commit 7b229bb
5 files changed
Lines changed: 199 additions & 54 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
37 | 37 | | |
38 | 38 | | |
39 | 39 | | |
40 | | - | |
| 40 | + | |
| 41 | + | |
41 | 42 | | |
42 | 43 | | |
43 | 44 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
7 | | - | |
8 | | - | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
9 | 10 | | |
10 | 11 | | |
11 | 12 | | |
12 | 13 | | |
13 | 14 | | |
14 | 15 | | |
15 | 16 | | |
16 | | - | |
| 17 | + | |
17 | 18 | | |
18 | 19 | | |
19 | 20 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
31 | 37 | | |
32 | 38 | | |
33 | 39 | | |
34 | | - | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
35 | 49 | | |
36 | | - | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
37 | 54 | | |
38 | 55 | | |
39 | 56 | | |
| |||
164 | 181 | | |
165 | 182 | | |
166 | 183 | | |
167 | | - | |
| 184 | + | |
| 185 | + | |
168 | 186 | | |
169 | 187 | | |
170 | 188 | | |
171 | 189 | | |
172 | 190 | | |
173 | | - | |
| 191 | + | |
174 | 192 | | |
175 | 193 | | |
176 | 194 | | |
| |||
190 | 208 | | |
191 | 209 | | |
192 | 210 | | |
193 | | - | |
| 211 | + | |
| 212 | + | |
194 | 213 | | |
195 | 214 | | |
196 | 215 | | |
197 | 216 | | |
198 | 217 | | |
199 | | - | |
| 218 | + | |
200 | 219 | | |
201 | 220 | | |
202 | 221 | | |
| |||
205 | 224 | | |
206 | 225 | | |
207 | 226 | | |
208 | | - | |
209 | | - | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
210 | 230 | | |
211 | 231 | | |
212 | 232 | | |
| |||
0 commit comments