Not really a kotlin question, but rather a gradle....
# announcements
a
Not really a kotlin question, but rather a gradle. How should we check if option like
--info
or
--verbose
is passed within a task 👀 when creating the task blob thinking upside down
r
There’s a gradle slack: https://gradle-community.slack.com/
a
Oh thanks! 😅
Btw I found something java-related, is there's kts equivalent (and maybe smaller, probably not defining a task class) https://docs.gradle.org/current/userguide/custom_tasks.html#example_declaring_a_command_line_option
r
It sounds like you want logging levels; I think you should just be logging at the appropriate level in your task, and letting gradle handle the command line level option: https://docs.gradle.org/current/userguide/logging.html
👍 1
a
Oh, yep, thanks!! 🙂
Still is there any way to get the option directly if passed?
r
Don’t know, I’d ask in the gradle slack
👍 1
v
I think so
Copy code
gradle.startParameter.logLevel
👀 1
👍 1