kontena / mortar

The manifest shooter for Kubernetes
Apache License 2.0
145 stars 14 forks source link

add shot describe command #69

Closed jnummelin closed 5 years ago

jnummelin commented 6 years ago
$ bundle exec mortar describe  hello
NAMESPACE   KIND        NAME       
hello-world Endpoints   hello      
            Namespace   hello-world
hello-world Service     hello      
hello-world Deployment  hello      
hello-world Ingress     hello      
hello-world Certificate hello      
hello-world Issuer      letsencrypt

supports also -o yaml option to dump everything in yaml.

kke commented 6 years ago

I don't see any conditional for $stdout.tty? or such in Rouge::Formatters::Terminal256. I think if the output of mortar describe will include the color escape-sequences when piped to a command or redirected to a file.

jnummelin commented 6 years ago

right, we need to handle that part in mortar side I think

jnummelin commented 6 years ago

the non-tty case is now handled properly for json output. it was already handled for yaml output