Exclude Script From Build

Hi,

Is there a way to exclude a script from a build? except those way:

  • #if UNITY_2022 # endif
  • Moving the script file to Editor folder.
  • Using an Assembly definition.

This guy manage to do it but I don’t know how :confused:

I am hoping for a magical Asset.Flag = Hidden or a static List assetToExludeAtBuild :smile:

Edit:
I think I can do that using BuildPipeline…

That’s easy to fix! Buy his product!

Bump.