Skip to content

Instantly share code, notes, and snippets.

View rctrj's full-sized avatar
🎮
Probably Playing

Rachit Raj rctrj

🎮
Probably Playing
  • India
View GitHub Profile
@aquarhead
aquarhead / build.rs
Last active August 15, 2023 12:35
Fully Automated Rust Code Generation for Large Protobuf/gRPC Repos
use std::{collections::HashSet, env, fmt::Write, fs, path::Path};
use walkdir::WalkDir;
type Res = Result<(), Box<dyn std::error::Error>>;
// replace:
// "ROOT DIR": root dir of proto files to generate
// "INCLUDE DIR": where all "package" specifier based on
// "REPO DIR": where to monitor change for build.rs rerun