Can i run a prebuild scripts for a configuration without running the player build?
MaroLFC opened this issue · 3 comments
My Use case is the following. I create a pre-build script that builds the addressable for my project but sometimes I only need the addressable build and not the player build is there a way to abort the player build and continue to the other build configurations?
Hi @MaroLFC, yes, this is possible. If your custom script implements the IPreBuildPerPlatformActionCanConfigureEditor
interface, you'll see a 'Configures Editor' checkbox appear on your build action, like so:
If you check this, the action will then be run when the 'Configure Editor Environment' button is pressed, which runs any pre-build actions with this option enabled, but doesn't run the build itself, or any post-build actions.
Here's an example of a class implementing the interface. There are no member functions to implement, the interface is just used as a means to filter out which pre-build actions should be considered when configuring the Editor:
public class Example: BuildAction, IPreBuildAction, IPreBuildPerPlatformAction, IPostBuildAction, IPostBuildPerPlatformAction, IPreBuildPerPlatformActionCanConfigureEditor
{
}
Hope this helps!
Thank you so much that is a great feature I will use it right away. Can I do the same for the build configurations? like control the Enable and disable of builds through a prebuild action.
Another question
I would like to contribute to the project with some of the Build actions I created. How can I do that?
Sorry for bothering you and thanks again
Another question also can i run the configure editor environment button using cli