Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cosmos-sdk-proto: add serde derive macros #471

Merged
merged 24 commits into from
Aug 13, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
format
  • Loading branch information
ash-burnt committed Aug 13, 2024
commit 41b9a2151d854e3f3b70210296af32aca1987f5a
14 changes: 10 additions & 4 deletions proto-build/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -380,10 +380,16 @@ fn copy_and_patch(src: impl AsRef<Path>, dest: impl AsRef<Path>) -> io::Result<(
// TODO(tarcieri): figure out what's wrong with our `buf` config and do it there
("::prost_types::", "::tendermint_proto::google::protobuf::"),
// add the feature flag to the serde definitions
("impl serde::Serialize for", "#[cfg(feature = \"serde\")]\n\
impl serde::Serialize for"),
("impl<'de> serde::Deserialize<'de> for", "#[cfg(feature = \"serde\")]\n\
impl<'de> serde::Deserialize<'de> for")
(
"impl serde::Serialize for",
"#[cfg(feature = \"serde\")]\n\
impl serde::Serialize for",
),
(
"impl<'de> serde::Deserialize<'de> for",
"#[cfg(feature = \"serde\")]\n\
impl<'de> serde::Deserialize<'de> for",
),
];

// Skip proto files belonging to `EXCLUDED_PROTO_PACKAGES`
Expand Down
Loading