Build->Build Reflection Captures from command-line

Hi UE Community!

I’m working on automating our pipeline. Right now I’m battling with reflection captures. Using the button in the editor works fine but my command doesn’t seem to be working:

“C:\Program Files\Epic Games\UE_4.21\Engine\Binaries\Win64\UE4Editor-Cmd.exe” “path o\project.uproject” -run=ResavePackages -buildReflectionCaptures -allowcommandletrendering -allmaps

Is this command equivalent to what the “Build Reflection Captures” menu option is doing?

Is this the best way to handle generating reflection captures? Is there something I’m missing?

I noticed that on a clean project folder (no BuiltData folders) the command above wouldn’t create those folders. I tried running the -bulidlighting command:

“C:\Program Files\Epic Games\UE_4.21\Engine\Binaries\Win64\UE4Editor-Cmd.exe” “path o\project.uproject” -run=ResavePackages -buildLighting -quality=Preview -allowcommandletrendering -allmaps

This created the corresponding BuiltData folders but when I ran the buildReflectionCaptures command but it still didn’t work.

Thanks for any help and guidance you can provide!

For anyone else having this problem: it was the right idea but the wrong argument. It has to be all lowercase,"-buildreflectioncaptures", and you can find it in their source code if you have access at UnrealEngine/Engine/Source/Editor/UnrealEd/Private/Commandlets