uselagoon / lagoon-cli

A CLI for Lagoon - Docker Build and Deploy System for Kubernetes
https://uselagoon.github.io/lagoon-cli
MIT License
24 stars 15 forks source link

Output `lagoon get environment` in a nicer format. #133

Open klonos opened 4 years ago

klonos commented 4 years ago

Currently the output of lagoon get environment -p PROJECT -e ENVIRONMENT is really wide.

Can we please have it in a nicer output, which would allow us to also grep things? Something like lagoon get environment -p PROJECT -e ENVIRONMENT | autoidle for example should out put something like: autoidle: 1. Routes and other multi-value things would be rendered in new lines too.

klonos commented 4 years ago

...alternatively, being able to pass the info name as parameter to the command would be nice. Something like:

lagoon get environment -autoidle -p PROJECT -e ENVIRONMENT

GROwen commented 4 years ago

@klonos This doesn't solve your exact use case but passing the --output-json and --pretty flags to the commands helps in tidying up the output. That at least makes it easier to pipe the output to grep i.e.

lagoon get environment -p project -e env --output-json --pretty | grep autoidle

returns "autoidle": "1",

tobybellwood commented 1 year ago

Adding to the rewrite to-do list, along with selectable fields.