fermyon / cloud-plugin

A Spin plugin for the Spin CLI for managing Spin apps in Fermyon Cloud.
https://developer.fermyon.com/cloud/
Apache License 2.0
8 stars 13 forks source link

Add support for formatting output of `cloud apps list` and `cloud apps info` #212

Closed ThorstenHans closed 2 weeks ago

ThorstenHans commented 3 weeks ago

This PR adds the --format flag (values Plain & Json) to the following commands:

The enum contains the Plain variant (which is also set as default value for both commands) due to backward compatibility reasons.

ThorstenHans commented 2 weeks ago

Thanks for the reviews @vdice and @itowlson

trying to mimic the behavior we have in place for plain text for json wasn't the smartest idea. I changed the way AppInfo is created and went with a simple String for Description instead of an Option it feels more natural to have a constant schema in JSON.

Thanks once again @itowlson for all those great suggestions 💪🏻