pub fn compile_protos_with_config(
        self,
        mut config: Config,
        protos: &[impl AsRef<Path>],
        includes: &[impl AsRef<Path>],
    ) -> io::Result<()> {
        if self.emit_rerun_if_changed {
            for path in protos.iter() {
                println!("cargo:rerun-if-changed={}", path.as_ref().display())
            }

            for path in includes.iter() {
                // Cargo will watch the **entire** directory recursively. If we
                // could figure out which files are imported by our protos we
                // could specify only those files instead.
                println!("cargo:rerun-if-changed={}", path.as_ref().display())
            }
        }

        self.setup_config(&mut config);
        config.compile_protos(protos, includes)
    }
Compile the .proto files and execute code generation using a custom
`prost_build::Config`. The provided config will be updated with this builder's config.
tonic-build/src/prost.rs