I'm trying to run gradle-profiler in order to get ...
# community-support
c
I'm trying to run gradle-profiler in order to get a better handle on my build times. I've done this before (maybe like 2 years ago?) and I saved my instructions, but apparently something changed? 1. install gradle-profiler via brew 2. go to project and add a scenarios.txt
Copy code
clean_build_1gb {
    tasks = [":app:assembleFreeDebug", "--rerun-tasks"]
    jvm-args = ["-Xmx1024m", "-Dkotlin.daemon.jvm.options=-Xmx1024m"]
}
3. run
gradle-profiler --benchmark --scenario-file scenarios.txt
It failed due to `org.gradle.cli.CommandLineArgumentException: Unknown command-line option --
rerun-tasks
If I remove it that flag then profiler command does work. if I run the command from scenarios.txt directly in my command line then it does work. Feel like I'm missing something basic here on how to profile a "clean" build?
oh jeez. im using the wrong formatting for defining the --rerun-tasks arg... arent i 🤦
a
I think it works if you use
Copy code
gradle-args = [
    "--rerun-tasks"
]
c
yep. that was indeed it. i guess my instructions i saved had this issue and i never noticed 😭
thank you for the pointer