1 2 3 4 5 6 7 8 9 10
use std::path::PathBuf; fn main() { let out_dir = PathBuf::from("src"); tonic_build::configure() .out_dir(out_dir) .compile(&["proto/zhiyan.proto"],&["proto"]) .unwrap(); }