radicle-cli icon indicating copy to clipboard operation
radicle-cli copied to clipboard

common: Add `Deserialize` and `Serialize` to `Identifier`

Open sebastinez opened this issue 2 years ago • 1 comments

I would benefit in radicle-client-services/http-api, if I could serialize and deserialize this enum from a string, IMO if we would check if it's only a prefix or a full git2::Oid we should be able to do just that. Am I missing something? Else would implement it in a PR.

https://github.com/radicle-dev/radicle-cli/blob/ea07d1c1327fd05e7792b771436744d415bf4fd9/common/src/cobs/shared.rs#L64

sebastinez avatar Jul 25 '22 12:07 sebastinez

Yeah, the code is basically there already (FromStr and Display), do you specifically need serde support?

cloudhead avatar Aug 01 '22 15:08 cloudhead

Closing this, since it's not relevant anymore

sebastinez avatar Dec 27 '22 19:12 sebastinez