diff options
| author | Jeff Carr <[email protected]> | 2024-10-22 06:25:31 -0500 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2024-10-22 06:25:31 -0500 |
| commit | d52e39025edcc8ec5bda4949a9dd65ce6499b870 (patch) | |
| tree | 7b0fa9d4fa1af16b57318bc4c0a5208fe318da7d /helpers.go | |
| parent | ed7dd145f607edb60df43f457e7e0013f4647aba (diff) | |
don't actually use prototext?
Signed-off-by: Jeff Carr <[email protected]>
Diffstat (limited to 'helpers.go')
| -rw-r--r-- | helpers.go | 11 |
1 files changed, 7 insertions, 4 deletions
@@ -24,10 +24,13 @@ func (c *Cluster) FormatJSON() string { return protojson.Format(c) } -func (c *Cluster) FormatTEXT() string { - return prototext.Format(c) -} - func (c *Cluster) UnmarshalJSON(data []byte) error { return protojson.Unmarshal(data, c) } + +// apparently this isn't supposed to be used? +// https://protobuf.dev/reference/go/faq/#unstable-text +// this is a shame because this is much nicer output than JSON Format() +func (c *Cluster) FormatTEXT() string { + return prototext.Format(c) +} |
