First push
This commit is contained in:
11
proto/Cargo.toml
Normal file
11
proto/Cargo.toml
Normal file
@@ -0,0 +1,11 @@
|
||||
[package]
|
||||
name = "proto"
|
||||
edition = "2021"
|
||||
version.workspace = true
|
||||
|
||||
[dependencies]
|
||||
prost.workspace = true
|
||||
prost-types.workspace = true
|
||||
|
||||
[build-dependencies]
|
||||
prost-build.workspace = true
|
||||
11
proto/build.rs
Normal file
11
proto/build.rs
Normal file
@@ -0,0 +1,11 @@
|
||||
pub fn main() {
|
||||
let proto_file = "StarRail.proto";
|
||||
if std::path::Path::new(proto_file).exists() {
|
||||
println!("cargo:rerun-if-changed={proto_file}");
|
||||
|
||||
prost_build::Config::new()
|
||||
.out_dir("out/")
|
||||
.compile_protos(&[proto_file], &["."])
|
||||
.unwrap();
|
||||
}
|
||||
}
|
||||
0
proto/out/.gitkeep
Normal file
0
proto/out/.gitkeep
Normal file
35124
proto/out/_.rs
Normal file
35124
proto/out/_.rs
Normal file
File diff suppressed because it is too large
Load Diff
1323
proto/src/cmd_types.rs
Normal file
1323
proto/src/cmd_types.rs
Normal file
File diff suppressed because it is too large
Load Diff
4
proto/src/lib.rs
Normal file
4
proto/src/lib.rs
Normal file
@@ -0,0 +1,4 @@
|
||||
mod cmd_types;
|
||||
pub use cmd_types::*;
|
||||
|
||||
include!("../out/_.rs");
|
||||
Reference in New Issue
Block a user