# proto.rs — Protobuf Module

<span style="white-space: pre-wrap;">This file simply includes the generated Rust code for the </span>`<span class="editor-theme-code">packets</span>`<span style="white-space: pre-wrap;"> protobuf module:</span>

rust

```rust
pub mod packets {
    include!(concat!(env!("OUT_DIR"), "/packets.rs"));
}
```

<span style="white-space: pre-wrap;">The actual </span>`<span class="editor-theme-code">.proto</span>`<span style="white-space: pre-wrap;"> source files live in </span>`<span class="editor-theme-code">src-tauri/proto/</span>`<span style="white-space: pre-wrap;">. They are compiled at build time by </span>`<span class="editor-theme-code">build.rs</span>`<span style="white-space: pre-wrap;"> into </span>`<span class="editor-theme-code">packets.rs</span>`<span style="white-space: pre-wrap;"> in the Cargo </span>`<span class="editor-theme-code">OUT_DIR</span>`<span style="white-space: pre-wrap;">. Importing </span>`<span class="editor-theme-code">crate::proto::packets::*</span>`<span style="white-space: pre-wrap;"> in any Rust file gives access to all the generated message structs.</span>