Display short field when running tasks
octplane opened this issue · comments
This is a feature request. Not sure this is an actual use case.
In my tasks, I run several generated tasks from one single task (such as apps:upload
that will upload a bunch of apps on a server).
The fact that Orbit does not show any information about the tasks it runs is a bit confusing. I had to recode some artificial debug info to make that more easy:
{{- $title := printf "Render and deploy app for %s to %s on %s" $.Orbit.Values.app.name $deploy.k8s_cluster $deploy.aws_account}}
- use: {{ $stage }}
short: {{ $title}}
run:
- echo "{{ $title }}"
The alternative is to run Orbit -d
but this is very verbose!
I wanted to know if it could be possible:
- either have a
-i
(likeinfo
) flag that would display this information - or inject an env variable so that the
run
code can access this information - or always print this information
Let me know what you think of this...
+1 on this!
I would also like to see the following behaviour:
- print task names by default. Add a
-q/--quiet
to remove those - Add a
-v/--verbose
option that would print the actual commands that are being run. This would serve as an alternative to-d
which is too verbose for regular end-users.
Thank you for the feedbacks! 😄
The first version of Orbit actually printed the current task name. However, I think it should not be the default behavior and we should let the user to decide whether or not he wants to print something.
@octplane does it the way I've imagined it.
Still, it could be interesting to have a -i/--info
flag with a info
function.
{{- $title := printf "Render and deploy app for %s to %s on %s" $.Orbit.Values.app.name $deploy.k8s_cluster $deploy.aws_account}}
- use: {{ $stage }}
short: {{ $title}}
run:
{{ if info }}
- echo "{{ $title }}"
{{ end }}
Or as asked by @octplane, printing the short
attribute when this flag is given to Orbit.