By default, for a c++ project, “WPILib Build” in VSCode builds the project six times: Athena debug/release, simulation debug/release, and test debug/release. Even when deploying, it still builds the code for both debug and release. Besides being slow, it’s annoying to see the same compiler errors repeated six times. Is there a way to only build the debug OR release build?
When deploying, Gradle will only build what it needs to. Are you certain that it is actually building both release and debug on deploy? You can run with
./gradlew deploy -Pdeploy-dry --console=plain, which should give some insight into what tasks are being run
Well, that only starts compiling release, but it also terminates early as I’m not connected to a RIO. And the ordinary
./gradlew build builds all six still.