Skip to content

Commit f7fc16e

Browse files
chore: bump from prerelease (makspll#237)
* chore: bump from prerelease * Add release notes draft * add changelog link * add image * Update 0.9.0.md * fix coverage badge workflow * make this work on branches * add script functions plugin as default installation instructions * fix coverage badge issue * chore(badge): Update coverage badge [skip ci] --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
1 parent 8b309a6 commit f7fc16e

File tree

9 files changed

+57
-18
lines changed

9 files changed

+57
-18
lines changed

.github/workflows/bevy_mod_scripting.yml

+10-2
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ jobs:
5252
permissions:
5353
pull-requests: write
5454
contents: write
55+
issues: write
5556
name: Check - ${{ matrix.run_args.name }}
5657
runs-on: ${{ matrix.run_args.os }}
5758
# container: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:latest
@@ -93,17 +94,24 @@ jobs:
9394
path: target/coverage/html/
9495

9596
- name: Update coverage badge
96-
if: ${{ matrix.run_args.generates_coverage && github.ref == 'refs/heads/main' }}
97+
if: ${{ matrix.run_args.generates_coverage }}
98+
continue-on-error: true
9799
run: |
100+
git checkout -b chore/_update-coverage-badge || git checkout chore/_update-coverage-badge
98101
cp target/coverage/html/badges/for_the_badge.svg badges/coverage.svg
99102
100103
git config user.name "github-actions[bot]"
101104
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
105+
git config --global push.autoSetupRemote true
102106
git add badges/coverage.svg
103107
104108
if [[ -n $(git status -s) ]]; then
105109
git commit -m "chore(badge): Update coverage badge" -m "[skip ci]"
106-
git push
110+
git push -f
111+
gh pr create --title "chore: Update coverage badge" --body "Updates coverage badge based on test results" --base ${{ github.ref }} --head chore/_update-coverage-badge > pr.txt
112+
sed -n 's/.*pull\/\([0-9]*\).*/\1/p' pr.txt > pr_number.txt
113+
PRNUMBER=$(cat pr_number.txt)
114+
gh pr merge $PRNUMBER --squash
107115
fi
108116
generate_bindings:
109117
name: Bindings - Synchronise

Cargo.toml

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "bevy_mod_scripting"
3-
version = "0.9.0-alpha.9"
3+
version = "0.9.0"
44
authors = ["Maksymilian Mozolewski <[email protected]>"]
55
edition = "2021"
66
license = "MIT OR Apache-2.0"
@@ -53,15 +53,15 @@ rhai = ["bevy_mod_scripting_rhai"]
5353
[dependencies]
5454
bevy = { workspace = true }
5555
bevy_mod_scripting_core = { workspace = true }
56-
bevy_mod_scripting_lua = { path = "crates/languages/bevy_mod_scripting_lua", version = "0.9.0-alpha.9", optional = true }
57-
bevy_mod_scripting_rhai = { path = "crates/languages/bevy_mod_scripting_rhai", version = "0.9.0-alpha.9", optional = true }
56+
bevy_mod_scripting_lua = { path = "crates/languages/bevy_mod_scripting_lua", version = "0.9.0", optional = true }
57+
bevy_mod_scripting_rhai = { path = "crates/languages/bevy_mod_scripting_rhai", version = "0.9.0", optional = true }
5858
# bevy_mod_scripting_rune = { path = "crates/languages/bevy_mod_scripting_rune", version = "0.9.0-alpha.2", optional = true }
5959
bevy_mod_scripting_functions = { workspace = true }
6060
[workspace.dependencies]
6161
profiling = { version = "1.0" }
6262
bevy = { version = "0.15.0", default-features = false }
63-
bevy_mod_scripting_core = { path = "crates/bevy_mod_scripting_core", version = "0.9.0-alpha.9" }
64-
bevy_mod_scripting_functions = { path = "crates/bevy_mod_scripting_functions", version = "0.9.0-alpha.9", default-features = false }
63+
bevy_mod_scripting_core = { path = "crates/bevy_mod_scripting_core", version = "0.9.0" }
64+
bevy_mod_scripting_functions = { path = "crates/bevy_mod_scripting_functions", version = "0.9.0", default-features = false }
6565

6666
# test utilities
6767
script_integration_test_harness = { path = "crates/script_integration_test_harness" }

badges/coverage.svg

+3-3
Loading

crates/bevy_mod_scripting_core/Cargo.toml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "bevy_mod_scripting_core"
3-
version = "0.9.0-alpha.9"
3+
version = "0.9.0"
44
authors = ["Maksymilian Mozolewski <[email protected]>"]
55
edition = "2021"
66
license = "MIT OR Apache-2.0"
@@ -40,7 +40,7 @@ dashmap = "6"
4040
smallvec = "1.11"
4141
itertools = "0.13"
4242
derivative = "2.2"
43-
profiling = {workspace = true}
43+
profiling = { workspace = true }
4444
[dev-dependencies]
4545
test_utils = { workspace = true }
4646

crates/bevy_mod_scripting_functions/Cargo.toml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "bevy_mod_scripting_functions"
3-
version = "0.9.0-alpha.9"
3+
version = "0.9.0"
44
edition = "2021"
55
authors = ["Maksymilian Mozolewski <[email protected]>"]
66
license = "MIT OR Apache-2.0"
@@ -30,7 +30,7 @@ bevy = { workspace = true, features = [
3030
"file_watcher",
3131
"multi_threaded",
3232
] }
33-
profiling = {workspace = true}
33+
profiling = { workspace = true }
3434
uuid = "1.11"
3535
smol_str = "0.2.2"
3636
bevy_mod_scripting_core = { workspace = true }

crates/languages/bevy_mod_scripting_lua/Cargo.toml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "bevy_mod_scripting_lua"
3-
version = "0.9.0-alpha.9"
3+
version = "0.9.0"
44
authors = ["Maksymilian Mozolewski <[email protected]>"]
55
edition = "2021"
66
license = "MIT OR Apache-2.0"
@@ -45,7 +45,7 @@ parking_lot = "0.12.1"
4545
uuid = "1.1"
4646
smol_str = "0.2.2"
4747
smallvec = "1.13"
48-
profiling = {workspace = true}
48+
profiling = { workspace = true }
4949

5050
[dev-dependencies]
5151
script_integration_test_harness = { workspace = true }

crates/languages/bevy_mod_scripting_rhai/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "bevy_mod_scripting_rhai"
3-
version = "0.9.0-alpha.9"
3+
version = "0.9.0"
44
authors = ["Maksymilian Mozolewski <[email protected]>"]
55
edition = "2021"
66
license = "MIT OR Apache-2.0"

docs/src/Summary/installation.md

+4-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,10 @@ Choose the language features you wish enabled and add them to the features block
1616
The next step is to add the BMS plugin to your application, on top of any other extras you want included in your app:
1717

1818
```rust,ignore
19-
app.add_plugins(LuaScriptingPlugin::default());
19+
app.add_plugins((
20+
LuaScriptingPlugin::default(),
21+
ScriptFunctionsPlugin
22+
));
2023
```
2124

2225
The above is how you'd setup BMS for Lua, if you want to use another language, simply use a corresponding plugin from the integration crate.

release-notes/0.9.0.md

+28
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# [`bevy_mod_scripting`](https://github.com/makspll/bevy_mod_scripting/) 0.9.0 is out!
2+
3+
![image](https://github.com/user-attachments/assets/6ae0f927-ea1b-4d90-a809-4cc513e49b18)
4+
5+
## Summary
6+
- The entire crate was completely re-written
7+
- We cut down the number of crates, moving most common functionality into the core crate and removing all the horrible macros
8+
- All of the systems have been made more robust and testable
9+
- The crate is now completely panic free!
10+
- The script lifecycle is automatically tied to script assets, loading and unloading assets and placing `ScriptComponent`'s on entities is all you need to do to manage the complexities of creating, updating, deleting and hot-loading script state.
11+
- A new `ScriptValue` abstraction allows us to centrally define and register dynamic script functions which automatically register their type dependencies with the `AppTypeRegistry`
12+
- New language implementations do not need to re-implement all of the bevy bindings, they simply need to provide a dynamic calling mechanism, and dispatch operators to the right functions
13+
- Bevy bindings generation is completely decoupled from `mlua`, in fact the BMS crate gets injected into the process of compiling `bevy` and in doing so we can look for types which implement `IntoScript` and `FromScript`, allowing us to react to changes in those trait implementations in picking which functions to generate registrations for.
14+
- The `APIProvider` traits as well as the `API` terminology were gotten rid of in favour of configuration resources with stored function pointers, as well as more specific `bindings` terminology
15+
- We now publish a brand new [book](https://makspll.github.io/bevy_mod_scripting/), which should help onboard new consumers and make the crate much easier to use!
16+
- The entire dev experience has been transformed thanks to the `xtask` pattern, contributing to `BMS` has never been easier!
17+
18+
## Removed
19+
- We removed `tealr` and the `teal` integration, meaning interacting with Lua is much simpler.
20+
21+
## On pause
22+
- We put documentation generation features as well as `rune` support on pause, to accelerate going forward. But there is nothing stopping us from re-implementing those features, and in fact generating documentation will be infinitely easier given we have trait level access to all dynamic functions!
23+
24+
## Migration Guide
25+
I am not publishing a migration guide, simply because the easiest way to migrate to 0.9.0 is to start from scratch! EVERYTHING is different, and hence I'd reccomend walking through the docs, and re-implenenting the crate.
26+
27+
## Changelog
28+
See a detailed changelog [here](https://github.com/makspll/bevy_mod_scripting/blob/main/CHANGELOG.md)

0 commit comments

Comments
 (0)