Skip to content

Commit bdc0aac

Browse files
docs: add detailed regeneration steps to README
Co-Authored-By: Tejas Badadare <[email protected]>
1 parent 75f8be8 commit bdc0aac

File tree

1 file changed

+16
-3
lines changed

1 file changed

+16
-3
lines changed

apps/hermes/client/rust/README.md

Lines changed: 16 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,22 @@ To regenerate the client after updates to the Hermes API:
9898

9999
3. Manually update dependencies in Cargo.toml and version number if necessary.
100100

101+
4. Create a `.openapi-generator-ignore` file to preserve custom implementations:
102+
```bash
103+
echo "src/streaming.rs" > .openapi-generator-ignore
104+
echo "examples/" >> .openapi-generator-ignore
105+
```
106+
107+
5. Implement custom streaming functionality in `src/streaming.rs` using the `eventsource-stream` crate for proper SSE handling.
108+
109+
6. Rename parameter names in the generated code to be more intuitive (e.g., in `rest_api.rs`).
110+
111+
7. Fix formatting and clippy linting issues:
112+
```bash
113+
cargo fmt
114+
cargo clippy --fix
115+
```
116+
101117
## Publishing
102118

103119
This package is published to crates.io when a new tag matching `hermes-client-rust-v*` is pushed.
@@ -125,6 +141,3 @@ The client defaults to using the Hermes public endpoint at https://hermes.pyth.n
125141
- [RpcPriceFeedMetadata](docs/RpcPriceFeedMetadata.md)
126142
- [RpcPriceFeedMetadataV2](docs/RpcPriceFeedMetadataV2.md)
127143
- [TwapsResponse](docs/TwapsResponse.md)
128-
129-
130-

0 commit comments

Comments
 (0)