rust-nex/rnex-server-api/build.rs
Maple Nebel af60878429
Some checks failed
Build and Test / friends (push) Failing after 4m3s
Build and Test / wii-u-chat (push) Successful in 5m33s
Build and Test / fast-racing-neo (push) Successful in 6m5s
Build and Test / puyopuyo (push) Successful in 6m7s
Build and Test / minecraft-wiiu (push) Successful in 6m14s
Build and Test / super-mario-maker (push) Successful in 6m34s
Build and Test / sonic-transformed (push) Successful in 10m14s
Build and Test / wii-sports-club (push) Successful in 10m53s
Build and Test / splatoon (push) Successful in 10m59s
Build and Test / splatoon-testfire (push) Successful in 10m59s
Build and Test / mario-tennis (push) Successful in 11m23s
3ds friends
2026-06-08 10:31:55 +02:00

24 lines
767 B
Rust

use std::{env, fs};
fn main() -> Result<(), Box<dyn std::error::Error>> {
println!("cargo:rerun-if-changed=build.rs");
println!("cargo:rerun-if-changed=../rnex-server-api-grpc/");
let protos: Vec<String> = fs::read_dir("../rnex-server-api-grpc/")?
.filter(|e| {
e.as_ref().is_ok_and(|e| {
e.file_name()
.to_str()
.is_some_and(|n| n.ends_with(".proto"))
})
})
.filter_map(|e| {
e.ok()
.map(|v| v.path().to_str().map(|v| v.to_owned()))
.flatten()
})
.collect();
tonic_prost_build::configure()
.compile_protos(&protos[..], &["../rnex-server-api-grpc/".to_owned()])?;
Ok(())
}