Closed HariSekhon closed 2 years ago
Generally, I agree, but the --output simple
will disable the spinner and also the emoji.
I think the emoji should be kept because it's not their fault that the spinner is spamming the log 😅
Maybe we can change the behavior so that when Datree recognizes it's running in a CI, it will not show (just) the spinner. @HariSekhon @shmuelsa WDYT?
Hey I've got nothing against emojis, down with the spinner in CI though.
This should probably also happen if datree recognizes that it's in a pipeline and stdout has been redirected, although I guess --output simple
could be used in that case.
Hey! Our app context has an internal package that detects very early if we're running in a CI ('CiContext'). we can rely on it in the initialization of the spinner base. @adifay maybe one of the community can help us with that
✅ To keep everyone in sync, the task definition is to detect when Datree is running in CI and disable the spinner.
⚠️ This task is NOT about detecting when Datree is running in CI and running Datree in simple mode (--output simple
)
Following on from this ticket:
https://github.com/datreeio/action-datree/issues/5
I think it would be good for datree to detect when it is running within a CI system and default to using simpler output to prevent generating huge logs or messing up the screen.
I am looking at adding
--output simple
to the CI myself for now, but I believe other tools already detect when running in CI and tone their output down automatically so this isn't a new idea.I even do this myself for my own code by checking for all the common environment variables for CI builds, eg:
https://github.com/HariSekhon/DevOps-Bash-tools/blob/master/lib/ci.sh