JetBrains / teamcity-unity-plugin

TeamCity plugin supports building Unity projects
Apache License 2.0
83 stars 38 forks source link

Option to remove "-quit" argument #63

Closed pierredeman closed 1 year ago

pierredeman commented 3 years ago

Add checkbox param to disable '-quit' command line option. Logic is inverted to avoid problems and keep "-quit" by default.

resolve #34

AaronZurawski commented 2 years ago

This does fix a case where you could use the previous logic to not add the "-quit" parameter by providing the "-runTests" argument in the argument list without setting the option to run tests in the runner settings. So in a way, this does break that previous behavior. I'm in favor of doing this since its a bit of an exploit of the logic and intent of the original code.

I think that is acceptable, especially given that this change gives you the ability to manually control the "-quit" option as an override and is a much cleaner and clearer way of handling it.

I've tested this and can confirm it works wonderfully, I recommend merging.

zsoi commented 2 years ago

This would be a really good addition to the plugin and make batch mode properly supported, as running -batchmode without -quit is a common and supported use-case.

GabeBigBoxVR commented 1 year ago

@pavel-krizskii @lesley29 @semyonnaumov Would it be possible for someone to review this? #34 is pretty common problem for game studios like our. We have workloads to bake lightmaps via scripts and it's impossible unless we can find a way to Omit the -quit argument.

pavel-krizskii commented 1 year ago

@pierredeman Thanks for the PR and we apologize for such a delay!

Everything looks good, I've added a couple of minor changes (mostly some refactoring and tests) in this commit.

@pierredeman if you get a chance, could you please check the final version of the pull request and let us know if there are any other suggestions

pierredeman commented 1 year ago

There was a small problem with the unit test UnityRunnerBuildServiceTest.should generate correct command line when virtual context is used. I pushed new commit to fix this, seems OK now :)