Add check to ensure plugin version matches cargo version (#794)

This modifies Rojo's build script to throw a fit if we're building a
plugin with a semver incompatible version. In the process, it moves the
version of the plugin to a file named `Version.txt` that's parsed at
runtime. This should be minimally invasive but it's technically worse
for performance than the hardcoded table and string we had before.

This feels better than a CI check or just manually verifying because it
makes it physically impossible for us to forget since Rojo won't build
with it being wrong.
This commit is contained in:
Micah
2023-10-03 07:29:47 -07:00
committed by GitHub
parent eab7c607cd
commit 010e50a25d
6 changed files with 60 additions and 28 deletions

5
Cargo.lock generated
View File

@@ -1916,6 +1916,7 @@ dependencies = [
"ritz",
"roblox_install",
"rojo-insta-ext",
"semver",
"serde",
"serde_json",
"serde_yaml",
@@ -2034,9 +2035,9 @@ dependencies = [
[[package]]
name = "semver"
version = "1.0.17"
version = "1.0.19"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "bebd363326d05ec3e2f532ab7660680f3b02130d780c299bca73469d521bc0ed"
checksum = "ad977052201c6de01a8ef2aa3378c4bd23217a056337d1d6da40468d267a4fb0"
[[package]]
name = "serde"